-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathMakefile
More file actions
36 lines (29 loc) · 832 Bytes
/
Makefile
File metadata and controls
36 lines (29 loc) · 832 Bytes
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: setup start stop restart logs build clean
# First-run setup: create .env from template if not exists
setup:
@if [ ! -f .env ]; then \
cp .env.example .env; \
echo "✅ Created .env from .env.example"; \
echo "⚠️ Edit .env to set BASIC_AUTH_USERNAME and BASIC_AUTH_PASSWORD"; \
else \
echo "ℹ️ .env already exists"; \
fi
@mkdir -p data logs config config/dnsmasq.d
# Build and start all services
start: setup
docker compose up -d --build
# Stop all services
stop:
docker compose down
# Restart with rebuild
restart: stop start
# View logs
logs:
docker compose logs -f --tail=50
# Build without starting
build: setup
docker compose build
# Clean everything (data preserved)
clean:
docker compose down -v --remove-orphans
@echo "⚠️ Data in ./data/ preserved. Remove manually if needed."