Updated docker-compose files for use with Docker Caddy

Defined top level name for all services
Added proxy-net to services
Updated main service/server container service name to "app"
Updated hostname references to projectname-app-1
Updated docker Caddy caddyfile to reference container names
Updated docker Caddy caddyfile to use 192.168.1.234 instead of localhost for non-docker services
Adjusted caddyfile accordingly
This commit is contained in:
Chris King
2025-01-12 23:37:59 -08:00
parent 342559c8eb
commit 28c734c1d2
14 changed files with 119 additions and 61 deletions

View File

@@ -1,6 +1,6 @@
name: authentik
services:
postgresql:
db:
image: docker.io/library/postgres:16-alpine
restart: unless-stopped
healthcheck:
@@ -29,13 +29,13 @@ services:
timeout: 3s
volumes:
- redis:/data
server:
app:
image: ${AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}:${AUTHENTIK_TAG:-2024.12.2}
restart: unless-stopped
command: server
environment:
AUTHENTIK_REDIS__HOST: redis
AUTHENTIK_POSTGRESQL__HOST: postgresql
AUTHENTIK_REDIS__HOST: authentik-redis-1
AUTHENTIK_POSTGRESQL__HOST: authentik-db-1
AUTHENTIK_POSTGRESQL__USER: ${PG_USER:-authentik}
AUTHENTIK_POSTGRESQL__NAME: ${PG_DB:-authentik}
AUTHENTIK_POSTGRESQL__PASSWORD: ${PG_PASS}
@@ -60,8 +60,8 @@ services:
restart: unless-stopped
command: worker
environment:
AUTHENTIK_REDIS__HOST: redis
AUTHENTIK_POSTGRESQL__HOST: postgresql
AUTHENTIK_REDIS__HOST: authentik-redis-1
AUTHENTIK_POSTGRESQL__HOST: authentik-db-1
AUTHENTIK_POSTGRESQL__USER: ${PG_USER:-authentik}
AUTHENTIK_POSTGRESQL__NAME: ${PG_DB:-authentik}
AUTHENTIK_POSTGRESQL__PASSWORD: ${PG_PASS}