chore: Add caddy helper commands
This commit is contained in:
parent
b0459af78f
commit
beb4a7fa6b
1 changed files with 9 additions and 0 deletions
9
Makefile
9
Makefile
|
|
@ -7,6 +7,7 @@ COMPOSE := DOCKER_HOST=$(DOCKER_HOST) $(COMPOSE_CMD)
|
|||
psql:
|
||||
$(COMPOSE) exec inventree-db sh -c 'psql $$POSTGRES_USER $$POSTGRES_DB'
|
||||
|
||||
.PHONY: update
|
||||
update:
|
||||
read -p "Update will cause downtime of the server. Are you sure you want to continue? Press Ctrl+c to abort!" _
|
||||
$(COMPOSE) pull
|
||||
|
|
@ -17,6 +18,14 @@ update:
|
|||
data: # podman does not autocreate data folder
|
||||
mkdir data
|
||||
|
||||
.PHONY: caddy-check
|
||||
caddy-check:
|
||||
docker run --rm --env-file .env -v ./Caddyfile:/etc/caddy/Caddyfile:ro,Z caddy:alpine caddy validate --config /etc/caddy/Caddyfile
|
||||
|
||||
.PHONY: caddy-print
|
||||
caddy-print:
|
||||
docker run --rm --env-file .env -v ./Caddyfile:/etc/caddy/Caddyfile:ro,Z caddy:alpine caddy adapt --config /etc/caddy/Caddyfile --pretty
|
||||
|
||||
# pass all commands to compose cli
|
||||
%: data
|
||||
$(COMPOSE) $@
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue