Skip to content

Commit 55a6f55

Browse files
committed
Authentik
1 parent b759bd9 commit 55a6f55

File tree

2 files changed

+101
-0
lines changed

2 files changed

+101
-0
lines changed

authentik/.env.example

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
AUTHENTIK_SECRET_KEY=<FILL IN>
2+
3+
# SMTP Host Emails are sent to
4+
AUTHENTIK_EMAIL__HOST=<MAIL SERVER HOSTNAME>
5+
AUTHENTIK_EMAIL__PORT=<MAIL SERVER PORT>
6+
7+
# Optionally authenticate (don't add quotation marks to your password)
8+
AUTHENTIK_EMAIL__USERNAME=<MAIL SERVER EMAIL/USERNAME>
9+
AUTHENTIK_EMAIL__PASSWORD=<MAIL SERVER PASSWORD>
10+
11+
# Use StartTLS
12+
AUTHENTIK_EMAIL__USE_TLS=false
13+
14+
# Use SSL
15+
AUTHENTIK_EMAIL__USE_SSL=true
16+
AUTHENTIK_EMAIL__TIMEOUT=10
17+
18+
# Email address authentik will send from, should have a correct @domain
19+
AUTHENTIK_EMAIL__FROM=info@pdxhackerspace.org
20+
21+
# Database config
22+
AUTHENTIK_POSTGRESQL__HOST=postgresql
23+
AUTHENTIK_POSTGRESQL__NAME=authentik_db
24+
AUTHENTIK_POSTGRESQL__USER=authentik_user
25+
AUTHENTIK_POSTGRESQL__PASSWORD=<DATABASE PASSWORD>
26+
27+
# Automatic database backup URL
28+
BACKUP_DATABASE_URLS=postgresql://authentik_user:<DATABASE PASSWORD>@postgresql:5432/authentik_db

authentik/docker-compose.yml

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
services:
2+
redis:
3+
image: docker.io/library/redis:alpine
4+
command: --save 60 1 --loglevel warning
5+
restart: unless-stopped
6+
healthcheck:
7+
test: ["CMD-SHELL", "redis-cli ping | grep PONG"]
8+
start_period: 20s
9+
interval: 30s
10+
retries: 5
11+
timeout: 3s
12+
volumes:
13+
- ../../lib/authentik/redis:/data
14+
networks:
15+
- redis
16+
17+
server:
18+
image: ${AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}:${AUTHENTIK_TAG:-2025.8.3}
19+
restart: unless-stopped
20+
command: server
21+
hostname: authentik-server
22+
environment:
23+
AUTHENTIK_REDIS__HOST: redis
24+
volumes:
25+
- ../../lib/authentik/media:/media
26+
- ../../lib/authentik/custom-templates:/templates
27+
env_file:
28+
- .env
29+
# ports:
30+
# - "${COMPOSE_PORT_HTTP:-9000}:9000"
31+
# - "${COMPOSE_PORT_HTTPS:-9443}:9443"
32+
depends_on:
33+
- redis
34+
networks:
35+
- proxy
36+
- redis
37+
- database
38+
39+
worker:
40+
image: ${AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}:${AUTHENTIK_TAG:-2025.8.3}
41+
restart: unless-stopped
42+
command: worker
43+
environment:
44+
AUTHENTIK_REDIS__HOST: redis
45+
# `user: root` and the docker socket volume are optional.
46+
# See more for the docker socket integration here:
47+
# https://goauthentik.io/docs/outposts/integrations/docker
48+
# Removing `user: root` also prevents the worker from fixing the permissions
49+
# on the mounted folders, so when removing this make sure the folders have the correct UID/GID
50+
# (1000:1000 by default)
51+
user: root
52+
volumes:
53+
- /var/run/docker.sock:/var/run/docker.sock
54+
- ../../lib/authentik/media:/media
55+
- ../../lib/authentik/certs:/certs
56+
- ../../lib/authentik/custom-templates:/templates
57+
env_file:
58+
- .env
59+
depends_on:
60+
- redis
61+
networks:
62+
- redis
63+
- database
64+
65+
networks:
66+
proxy:
67+
external: true
68+
name: nginx-proxy-net
69+
database:
70+
external: true
71+
name: postgres-net
72+
redis:
73+
name: authentik-redis-net

0 commit comments

Comments
 (0)