2018-06-14 09:06:04 -07:00
|
|
|
NANOC = bundle exec nanoc
|
|
|
|
|
GUARD = bundle exec guard
|
2023-03-10 23:00:33 +01:00
|
|
|
DOWNLOADS := prometheus alertmanager blackbox_exporter consul_exporter graphite_exporter memcached_exporter mysqld_exporter node_exporter promlens pushgateway statsd_exporter
|
2016-04-16 03:40:58 -04:00
|
|
|
|
2017-11-08 10:53:38 +01:00
|
|
|
build: clean downloads compile
|
|
|
|
|
|
2018-06-14 09:06:04 -07:00
|
|
|
bundle:
|
|
|
|
|
bundle config build.nokogiri --use-system-libraries
|
2025-03-11 09:46:08 +01:00
|
|
|
bundle config set path vendor
|
|
|
|
|
bundle install
|
2018-06-14 09:06:04 -07:00
|
|
|
|
2016-04-16 03:40:58 -04:00
|
|
|
clean:
|
2020-10-14 20:04:54 +02:00
|
|
|
rm -rf output downloads
|
2016-04-16 03:40:58 -04:00
|
|
|
|
2017-10-10 18:36:14 +02:00
|
|
|
compile:
|
2018-06-14 09:06:04 -07:00
|
|
|
$(NANOC)
|
2015-06-03 01:05:27 -04:00
|
|
|
|
2016-04-16 03:40:58 -04:00
|
|
|
downloads: $(DOWNLOADS:%=downloads/%/repo.json) $(DOWNLOADS:%=downloads/%/releases.json)
|
|
|
|
|
|
|
|
|
|
downloads/%/repo.json:
|
2016-04-18 23:04:52 -04:00
|
|
|
@mkdir -p $(dir $@)
|
2016-04-18 23:12:22 -04:00
|
|
|
@echo "curl -sf -H 'Accept: application/vnd.github.v3+json' <GITHUB_AUTHENTICATION> https://api.github.com/repos/prometheus/$* > $@"
|
2016-04-18 23:04:52 -04:00
|
|
|
@curl -sf -H 'Accept: application/vnd.github.v3+json' $(GITHUB_AUTHENTICATION) https://api.github.com/repos/prometheus/$* > $@
|
2016-04-16 03:40:58 -04:00
|
|
|
|
|
|
|
|
downloads/%/releases.json:
|
2016-04-18 23:04:52 -04:00
|
|
|
@mkdir -p $(dir $@)
|
2016-04-18 23:12:22 -04:00
|
|
|
@echo "curl -sf -H 'Accept: application/vnd.github.v3+json' <GITHUB_AUTHENTICATION> https://api.github.com/repos/prometheus/$*/releases > $@"
|
2016-04-18 23:04:52 -04:00
|
|
|
@curl -sf -H 'Accept: application/vnd.github.v3+json' $(GITHUB_AUTHENTICATION) https://api.github.com/repos/prometheus/$*/releases > $@
|
2016-04-16 03:40:58 -04:00
|
|
|
|
2018-06-14 09:06:04 -07:00
|
|
|
guard:
|
|
|
|
|
$(GUARD)
|
|
|
|
|
|
|
|
|
|
serve:
|
|
|
|
|
$(NANOC) view
|
|
|
|
|
|
|
|
|
|
.PHONY: build bundle clean compile downloads serve
|