-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompose.yml
136 lines (131 loc) · 4.39 KB
/
compose.yml
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
services:
redis:
image: redis:alpine
command: --save 60 1 --loglevel warning
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "redis-cli ping | grep PONG"]
start_period: 20s
interval: 30s
retries: 5
timeout: 3s
volumes:
- redis-storage:/data
ports:
- "6379:6379"
timescale:
image: timescale/timescaledb-ha:pg16
restart: unless-stopped
environment:
POSTGRES_USER: postgres # timscale doesnt let us change it
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?database password required}
POSTGRES_DATABASE: ${POSTGRES_DATABASE:-eidash}
volumes:
- timescale-storage:/home/postgres/pgdata/data
- ./docker/timescale/migrations:/docker-entrypoint-initdb.d
healthcheck:
test:
[
"CMD-SHELL",
"pg_isready -d $${POSTGRES_DATABASE} -U $${POSTGRES_USER}",
]
start_period: 20s
interval: 30s
retries: 5
timeout: 5s
deploy:
resources:
limits:
cpus: "4"
memory: 2G
ports:
- 5432:5432
authentik_postgres:
image: postgres:16-alpine
environment:
POSTGRES_PASSWORD: ${AUTHENTIK_POSTGRES_PASSWORD:?database password required}
POSTGRES_USER: ${AUTHENTIK_POSTGRES_USER:-authentik}
POSTGRES_DATABASE: ${AUTHENTIK_POSTGRES_DATABASE:-authentik}
volumes:
- authentik-postgres-storage:/var/lib/postgresql/data
- ./docker/postgres/postgresql.conf/:/etc/postgresql/postgresql.conf
ports:
- "${AUTHENTIK_POSTGRES_PORT:-6432}:5432"
restart: unless-stopped
healthcheck:
test:
[
"CMD-SHELL",
"pg_isready -d $${POSTGRES_DATABASE} -U $${POSTGRES_USER}",
]
start_period: 20s
interval: 30s
retries: 5
timeout: 5s
deploy:
resources:
limits:
cpus: "2"
memory: 1G
authentik_server:
image: ${AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}:${AUTHENTIK_TAG:-2023.10.4}
restart: unless-stopped
command: server
environment:
AUTHENTIK_SECRET_KEY: ${AUTHENTIK_SECRET_KEY:?secret key required}
AUTHENTIK_REDIS__HOST: redis
AUTHENTIK_REDIS__DB: 1
AUTHENTIK_POSTGRESQL__HOST: ${AUTHENTIK_POSTGRES_HOST:-authentik_postgres}
AUTHENTIK_POSTGRESQL__USER: ${AUTHENTIK_POSTGRES_USER:-authentik}
AUTHENTIK_POSTGRESQL__NAME: ${AUTHENTIK_POSTGRES_DATABASE:-authentik}
AUTHENTIK_POSTGRESQL__PASSWORD: ${AUTHENTIK_POSTGRES_PASSWORD}
AUTHENTIK_EMAIL__HOST: ${AUTHENTIK_EMAIL__HOST}
AUTHENTIK_EMAIL__PORT: ${AUTHENTIK_EMAIL__PORT}
AUTHENTIK_EMAIL__USERNAME: ${AUTHENTIK_EMAIL__USERNAME}
AUTHENTIK_EMAIL__PASSWORD: ${AUTHENTIK_EMAIL__PASSWORD}
AUTHENTIK_EMAIL__FROM: ${AUTHENTIK_EMAIL__FROM}
AUTHENTIK_EMAIL__USE_TLS: ${AUTHENTIK_EMAIL__USE_TLS}
volumes:
- ./docker/authentik/media:/media
- ./docker/authentik/custom-templates:/templates
env_file:
- .env
ports:
- "${COMPOSE_PORT_HTTP:-9000}:9000"
- "${COMPOSE_PORT_HTTPS:-9443}:9443"
depends_on:
- authentik_postgres
- redis
authentik_worker:
image: ${AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}:${AUTHENTIK_TAG:-2023.10.4}
restart: unless-stopped
command: worker
environment:
AUTHENTIK_SECRET_KEY: ${AUTHENTIK_SECRET_KEY:?secret key required}
AUTHENTIK_REDIS__HOST: redis
AUTHENTIK_REDIS__DB: 1
AUTHENTIK_POSTGRESQL__HOST: ${AUTHENTIK_POSTGRES_HOST:-authentik_postgres}
AUTHENTIK_POSTGRESQL__USER: ${AUTHENTIK_POSTGRES_USER:-authentik}
AUTHENTIK_POSTGRESQL__NAME: ${AUTHENTIK_POSTGRES_DATABASE:-authentik}
AUTHENTIK_POSTGRESQL__PASSWORD: ${AUTHENTIK_POSTGRES_PASSWORD}
AUTHENTIK_EMAIL__HOST: ${AUTHENTIK_EMAIL__HOST}
AUTHENTIK_EMAIL__PORT: ${AUTHENTIK_EMAIL__PORT}
AUTHENTIK_EMAIL__USERNAME: ${AUTHENTIK_EMAIL__USERNAME}
AUTHENTIK_EMAIL__PASSWORD: ${AUTHENTIK_EMAIL__PASSWORD}
AUTHENTIK_EMAIL__FROM: ${AUTHENTIK_EMAIL__FROM}
AUTHENTIK_EMAIL__USE_TLS: ${AUTHENTIK_EMAIL__USE_TLS}
user: root
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./docker/authentik/media:/media
- ./docker/authentik/certs:/certs
- ./docker/authentik/custom-templates:/templates
env_file:
- .env
depends_on:
- authentik_postgres
- redis
volumes:
authentik-postgres-storage:
redis-storage:
timescale-storage: