-
Notifications
You must be signed in to change notification settings - Fork 6
/
Makefile
36 lines (29 loc) · 946 Bytes
/
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
.PHONY: create-network
.create-network:
@docker network create traefik 2> /dev/null && echo "Created network traefik" || echo "Network traefik already exists"
.PHONY: configure-local-settings
.configure-local-settings:
@mkdir -p acme
@touch -a acme/acme.json && chmod 600 acme/acme.json
@cp -n .env.example .env || true
@cp -n authelia/users.yml.example authelia/users.yml || true
@cp -n -R authelia/secrets.example authelia/secrets && chmod 600 authelia/secrets/* || true
@./bin/populate-secrets.sh
.PHONY: build
.build:
@echo "Building docker images..." && docker compose build 2>&1 >/dev/null
.PHONY: up
.up:
@echo "Starting service..." && docker compose up -d
.PHONY: down
.down:
@docker compose down -v || true
.PHONY: target
target: .create-network .configure-local-settings .build .down .up
.PHONY: clean
clean:
docker compose down -v || true
rm -f acme/*
rm -rf authelia/secrets
rm -rf authelia/users.yml
rm -f .env