forked from autopilotpattern/elk
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmakefile
53 lines (40 loc) · 1.34 KB
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
MAKEFLAGS += --warn-undefined-variables
SHELL := /bin/bash
.SHELLFLAGS := -eu -o pipefail
.DEFAULT_GOAL := build
PHONY: *
# -------------------------------------------
# build and release
build:
docker-compose -f local-compose.yml -p elk build kibana logstash
cd nginx && docker build -t="elk_nginx_demo" .
ship:
docker tag -f elk_kibana autopilotpattern/kibana
docker tag -f elk_logstash autopilotpattern/logstash
docker tag -f elk_nginx_demo autopilotpattern/elk-nginx-demo
docker push autopilotpattern/kibana
docker push autopilotpattern/logstash
docker push autopilotpattern/elk-nginx-demo
# -------------------------------------------
# run on Triton
run:
./test.sh
# with 3 ES data nodes and 2 kibana app instances
scale:
docker-compose -p elk scale elasticsearch=3
docker-compose -p elk scale kibana=2
# run test for test-syslog, test-gelf (or test-fluentd once it works)
test-%:
./test.sh test $*
# -------------------------------------------
# run against a local Docker environment
local:
-docker-compose -p elk stop || true
-docker-compose -p elk rm -f || true
docker-compose -p elk -f local-compose.yml pull
docker-compose -p elk -f local-compose.yml build
./test.sh -f local-compose.yml
# test for local-test-syslog, local-test-gelf
# (or local-test-fluentd once it works)
local-test-%:
./test.sh -f local-compose.yml test $*