pxe-stack/docker-compose.yml
2023-07-21 12:57:51 +02:00

66 lines
1.6 KiB
YAML

---
version: '3'
# environment values for the core stack
x-common-keys-core: &common-keys-core
security_opt:
- no-new-privileges:true
restart: always
services:
apt-cacher-ng:
<<: *common-keys-core # see variables at the top of the yml file
image: sameersbn/apt-cacher-ng:latest
container_name: apt-cacher-ng
ports:
- "3142:3142"
volumes:
- cache:/var/cache/apt-cacher-ng
- config:/etc/apt-cacher-ng
healthcheck:
test: wget --no-verbose --tries=1 --spider http://localhost:3142/acng-report.html || exit 1
interval: 60s
retries: 5
start_period: 20s
timeout: 10s
git-init:
image: codeberg.org/angestoepselt/git-alpine:latest
security_opt:
- no-new-privileges:true
container_name: git-init
volumes:
- tftp-data:/git
nginx:
<<: *common-keys-core # see variables at the top of the yml file
image: nginx:mainline-alpine3.17-slim
container_name: webserver
ports:
- "${HTTP_PORT:-80}:80"
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
- tftp-data:/app/static:ro
healthcheck:
test: wget --no-verbose --tries=1 --spider http://localhost || exit 1
interval: 60s
retries: 5
start_period: 20s
timeout: 10s
tftp:
<<: *common-keys-core # see variables at the top of the yml file
image: codeberg.org/angestoepselt/tftp-server:latest
container_name: tftp
ports:
- "69:69/udp"
volumes:
- tftp-data:/var/tftp
depends_on:
- git-init
# this image has a build in healthcheck
volumes:
cache:
config:
tftp-data: