23 lines
488 B
Makefile
23 lines
488 B
Makefile
FILES = bad-referrers bad-user-agents
|
|
TMPFILES = $(patsubst %,.tmp/%.list, $(FILES))
|
|
TARGETS = $(patsubst %,snippets.d/%.conf, $(FILES))
|
|
|
|
all: $(TMPFILES) $(TARGETS)
|
|
|
|
download: $(TMPFILES)
|
|
|
|
.tmp/%.list:
|
|
mkdir -p .tmp
|
|
curl -s "https://raw.githubusercontent.com/mitchellkrogza/apache-ultimate-bad-bot-blocker/master/_generator_lists/$*.list" -o ".tmp/$*.list"
|
|
|
|
|
|
snippets.d/%.conf: .tmp/%.list
|
|
./generate_config.sh $@
|
|
|
|
clean:
|
|
rm -rf snippets.d/* .tmp
|
|
|
|
.PHONY: all clean
|
|
.SILENT: all
|
|
|