forked from coop-cloud/authentik
Compare commits
1 Commits
1.4.2+2023
...
copy_asset
Author | SHA1 | Date | |
---|---|---|---|
63e8cffa5e |
45
.drone.yml
45
.drone.yml
@ -1,45 +0,0 @@
|
|||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
name: deploy to swarm-test.autonomic.zone
|
|
||||||
steps:
|
|
||||||
- name: deployment
|
|
||||||
image: git.coopcloud.tech/coop-cloud/stack-ssh-deploy:latest
|
|
||||||
settings:
|
|
||||||
host: swarm-test.autonomic.zone
|
|
||||||
stack: authentik
|
|
||||||
generate_secrets: true
|
|
||||||
purge: true
|
|
||||||
deploy_key:
|
|
||||||
from_secret: drone_ssh_swarm_test
|
|
||||||
networks:
|
|
||||||
- proxy
|
|
||||||
environment:
|
|
||||||
DOMAIN: authentik.swarm-test.autonomic.zone
|
|
||||||
STACK_NAME: authentik
|
|
||||||
LETS_ENCRYPT_ENV: production
|
|
||||||
CUSTOM_CSS_VERSION: v1
|
|
||||||
CUSTOM_FLOWS_VERSION: v1
|
|
||||||
SECRET_SECRET_KEY_VERSION: v1
|
|
||||||
SECRET_DB_PASSWORD_VERSION: v1
|
|
||||||
SECRET_ADMIN_TOKEN_VERSION: v1
|
|
||||||
SECRET_ADMIN_PASS_VERSION: v1
|
|
||||||
SECRET_EMAIL_PASS_VERSION: v1
|
|
||||||
trigger:
|
|
||||||
branch:
|
|
||||||
- main
|
|
||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
name: generate recipe catalogue
|
|
||||||
steps:
|
|
||||||
- name: release a new version
|
|
||||||
image: plugins/downstream
|
|
||||||
settings:
|
|
||||||
server: https://build.coopcloud.tech
|
|
||||||
token:
|
|
||||||
from_secret: drone_abra-bot_token
|
|
||||||
fork: true
|
|
||||||
repositories:
|
|
||||||
- coop-cloud/auto-recipes-catalogue-json
|
|
||||||
|
|
||||||
trigger:
|
|
||||||
event: tag
|
|
29
.env.sample
29
.env.sample
@ -1,18 +1,26 @@
|
|||||||
TYPE=authentik
|
TYPE=authentik
|
||||||
LETS_ENCRYPT_ENV=production
|
LETS_ENCRYPT_ENV=production
|
||||||
|
|
||||||
DOMAIN=authentik.example.com
|
DOMAIN={{ .Domain }}
|
||||||
|
POSTGRES_PASSWORD=secret
|
||||||
|
AUTHENTIK_POSTGRESQL__PASSWORD=secret
|
||||||
|
POSTGRES_USER=authentik
|
||||||
AUTHENTIK_POSTGRESQL__USER=authentik
|
AUTHENTIK_POSTGRESQL__USER=authentik
|
||||||
|
POSTGRES_DB=authentik
|
||||||
AUTHENTIK_POSTGRESQL__NAME=authentik
|
AUTHENTIK_POSTGRESQL__NAME=authentik
|
||||||
AUTHENTIK_POSTGRESQL__HOST=db
|
AUTHENTIK_POSTGRESQL__HOST=db
|
||||||
AUTHENTIK_REDIS__HOST=redis
|
AUTHENTIK_REDIS__HOST=redis
|
||||||
AUTHENTIK_ERROR_REPORTING__ENABLED=true
|
AUTHENTIK_ERROR_REPORTING__ENABLED=true
|
||||||
# WORKERS=1
|
# WORKERS=1
|
||||||
|
AUTHENTIK_SECRET_KEY=secret
|
||||||
|
AK_ADMIN_TOKEN=secret
|
||||||
|
AK_ADMIN_PASS=secret
|
||||||
|
|
||||||
# EMAIL
|
# EMAIL
|
||||||
AUTHENTIK_EMAIL__HOST=smtp
|
AUTHENTIK_EMAIL__HOST=smtp
|
||||||
AUTHENTIK_EMAIL__PORT=25
|
AUTHENTIK_EMAIL__PORT=25
|
||||||
# AUTHENTIK_EMAIL__USERNAME=""
|
# AUTHENTIK_EMAIL__USERNAME=""
|
||||||
|
# AUTHENTIK_EMAIL__PASSWORD=""
|
||||||
AUTHENTIK_EMAIL__USE_TLS=false
|
AUTHENTIK_EMAIL__USE_TLS=false
|
||||||
AUTHENTIK_EMAIL__USE_SSL=false
|
AUTHENTIK_EMAIL__USE_SSL=false
|
||||||
AUTHENTIK_EMAIL__TIMEOUT=10
|
AUTHENTIK_EMAIL__TIMEOUT=10
|
||||||
@ -20,26 +28,15 @@ AUTHENTIK_EMAIL__FROM=noreply@example.com
|
|||||||
AUTHENTIK_LOG_LEVEL=info
|
AUTHENTIK_LOG_LEVEL=info
|
||||||
|
|
||||||
# Secret Versions
|
# Secret Versions
|
||||||
SECRET_SECRET_KEY_VERSION=v1
|
# SECRET_SECRET_KEY_VERSION=v1
|
||||||
SECRET_DB_PASSWORD_VERSION=v1
|
# SECRET_ADMIN_TOKEN_VERSION=v1
|
||||||
SECRET_ADMIN_TOKEN_VERSION=v1
|
# SECRET_ADMIN_PASS_VERSION=v1
|
||||||
SECRET_ADMIN_PASS_VERSION=v1
|
|
||||||
SECRET_EMAIL_PASS_VERSION=v1
|
|
||||||
|
|
||||||
# X_FRAME_OPTIONS_ALLOW_FROM=dashboard.example.org
|
# X_FRAME_OPTIONS_ALLOW_FROM=dashboard.example.org
|
||||||
AUTHENTIK_COLOR_BACKGROUND_LIGHT=#1c1e21
|
AUTHENTIK_COLOR_BACKGROUND_LIGHT=#1c1e21
|
||||||
AUTHENTIK_IMPERSONATION=true
|
|
||||||
|
|
||||||
## FLOW OPTIONS
|
## FLOW OPTIONS
|
||||||
WELCOME_MESSAGE="Welcome to Authentik"
|
WELCOME_MESSAGE="Welcome to Authentik"
|
||||||
DEFAULT_LANGUAGE=en
|
DEFAULT_LANGUAGE=en
|
||||||
AUTHENTIK_FOOTER_LINKS='[{"name": "My Organization","href":"https://example.com"}]'
|
AUTHENTIK_FOOTER_LINKS='[{"name": "My Organization","href":"https://example.com"}]'
|
||||||
LOGOUT_REDIRECT="https://$DOMAIN"
|
COPY_ASSETS="flow_background.jpg|app:/web/dist/assets/images/ icon_left_brand.svg|app:/web/dist/assets/icons/ icon.png|app:/web/dist/assets/icons/"
|
||||||
#COPY_ASSETS="flow_background.jpg|app:/web/dist/assets/images/"
|
|
||||||
#COPY_ASSETS="$COPY_ASSETS icon_left_brand.svg|app:/web/dist/assets/icons/
|
|
||||||
#COPY_ASSETS="$COPY_ASSETS icon.png|app:/web/dist/assets/icons/"
|
|
||||||
|
|
||||||
EMAIL_SUBJECT="Account Recovery"
|
|
||||||
EMAIL_TOKEN_EXPIRY_MINUTES=30
|
|
||||||
|
|
||||||
LOGOUT_REDIRECT=$DOMAIN
|
|
||||||
|
40
README.md
40
README.md
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
* **Category**: Apps
|
* **Category**: Apps
|
||||||
* **Status**: 0, work-in-progress
|
* **Status**: 0, work-in-progress
|
||||||
* **Image**: [ghcr/goauthentik/server](https://ghcr.io/goauthentik/server), 4, upstream
|
* **Image**: [ghcr/goauthentik/server](https://ghcr.io/goauthentik/server)
|
||||||
* **Healthcheck**: Yes
|
* **Healthcheck**: Yes
|
||||||
* **Backups**: Yes
|
* **Backups**: Yes
|
||||||
* **Email**: Yes
|
* **Email**: Yes
|
||||||
@ -20,44 +20,20 @@
|
|||||||
|
|
||||||
## Quick start
|
## Quick start
|
||||||
|
|
||||||
* `abra app new authentik`
|
* `abra app new authentik --secrets`
|
||||||
* `abra app config <app-name>`
|
* `abra app config <app-name>`
|
||||||
* `abra app secret insert <app_name> email_pass v1 <password>`
|
|
||||||
* `abra app secret generate -a <app_name>`
|
|
||||||
* `abra app deploy <app-name>`
|
* `abra app deploy <app-name>`
|
||||||
* `abra app cmd <app_name> app set_admin_pass`
|
|
||||||
|
|
||||||
## Rotate Secrets
|
|
||||||
|
|
||||||
Increment the secret versions using `abra app config <app_name>`
|
|
||||||
|
|
||||||
```
|
|
||||||
abra app secret generate -a <app_name>
|
|
||||||
abra app undeploy <app_name>
|
|
||||||
abra app deploy <app_name>
|
|
||||||
abra app cmd <app_name> db rotate_db_pass
|
|
||||||
abra app cmd <app_name> app set_admin_pass
|
|
||||||
```
|
|
||||||
|
|
||||||
## Customization
|
## Customization
|
||||||
|
|
||||||
Place the files you want to overwrite in a directory `<assets_path>`.
|
|
||||||
Run `abra app config <app_name>` and define the env variable `COPY_ASSETS` in the following format:
|
|
||||||
|
|
||||||
```
|
|
||||||
"<source_file1>|<service>:<target_directory1> <source_file2>|<service>:<target_directory2> ...
|
|
||||||
```
|
|
||||||
|
|
||||||
For example:
|
|
||||||
|
|
||||||
```
|
|
||||||
COPY_ASSETS="flow_background.jpg|app:/web/dist/assets/images/"
|
|
||||||
COPY_ASSETS="$COPY_ASSETS icon_left_brand.svg|app:/web/dist/assets/icons/
|
|
||||||
COPY_ASSETS="$COPY_ASSETS icon.png|app:/web/dist/assets/icons/"
|
|
||||||
```
|
|
||||||
|
|
||||||
Run this command after every deploy/upgrade:
|
Run this command after every deploy/upgrade:
|
||||||
|
|
||||||
`abra app command --local <app-name> customize <assets_path>`
|
`abra app command --local <app-name> customize <assets_path>`
|
||||||
|
|
||||||
|
This command replaces the background image, the logo and the favicon with the following files placed in the `<assets_path>` directory:
|
||||||
|
* `flow_background.jpg`
|
||||||
|
* `icon_left_brand.svg`
|
||||||
|
* `icon.png`
|
||||||
|
|
||||||
|
|
||||||
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
|
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
|
||||||
|
35
abra.sh
35
abra.sh
@ -1,5 +1,6 @@
|
|||||||
export CUSTOM_CSS_VERSION=v2
|
export CUSTOM_CSS_VERSION=v2
|
||||||
export CUSTOM_FLOWS_VERSION=v4
|
export CUSTOM_FLOWS_VERSION=v2
|
||||||
|
export RECOVERY_TEMPLATE_DE_VERSION=v1
|
||||||
|
|
||||||
customize() {
|
customize() {
|
||||||
if [ -z "$1" ]
|
if [ -z "$1" ]
|
||||||
@ -15,35 +16,3 @@ customize() {
|
|||||||
abra app cp $APP_NAME $asset_dir/$source $target
|
abra app cp $APP_NAME $asset_dir/$source $target
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
set_admin_pass() {
|
|
||||||
password=$(cat /run/secrets/admin_pass)
|
|
||||||
token=$(cat /run/secrets/admin_token)
|
|
||||||
/manage.py shell -c """
|
|
||||||
akadmin = User.objects.get(username='akadmin')
|
|
||||||
akadmin.set_password('$password')
|
|
||||||
akadmin.save()
|
|
||||||
print('Changed akadmin password')
|
|
||||||
|
|
||||||
from authentik.core.models import TokenIntents
|
|
||||||
key='$token'
|
|
||||||
if (token:= Token.objects.filter(identifier='authentik-bootstrap-token').first()):
|
|
||||||
token.key=key
|
|
||||||
token.save()
|
|
||||||
print('Changed authentik-bootstrap-token')
|
|
||||||
else:
|
|
||||||
Token.objects.create(
|
|
||||||
identifier='authentik-bootstrap-token',
|
|
||||||
user=akadmin,
|
|
||||||
intent=TokenIntents.INTENT_API,
|
|
||||||
expiring=False,
|
|
||||||
key=key,
|
|
||||||
)
|
|
||||||
print('Created authentik-bootstrap-token')
|
|
||||||
"""
|
|
||||||
}
|
|
||||||
|
|
||||||
rotate_db_pass() {
|
|
||||||
db_password=$(cat /run/secrets/db_password)
|
|
||||||
psql -U authentik -c """ALTER USER authentik WITH PASSWORD '$db_password';"""
|
|
||||||
}
|
|
||||||
|
91
compose.yml
91
compose.yml
@ -1,17 +1,19 @@
|
|||||||
---
|
---
|
||||||
|
|
||||||
x-env: &env
|
x-env: &env
|
||||||
- AUTHENTIK_POSTGRESQL__PASSWORD=file:///run/secrets/db_password
|
- AUTHENTIK_POSTGRESQL__PASSWORD
|
||||||
- AUTHENTIK_POSTGRESQL__USER
|
- AUTHENTIK_POSTGRESQL__USER
|
||||||
- AUTHENTIK_POSTGRESQL__NAME
|
- AUTHENTIK_POSTGRESQL__NAME
|
||||||
- AUTHENTIK_POSTGRESQL__HOST
|
- AUTHENTIK_POSTGRESQL__HOST
|
||||||
- AUTHENTIK_REDIS__HOST
|
- AUTHENTIK_REDIS__HOST
|
||||||
- AUTHENTIK_ERROR_REPORTING__ENABLED
|
- AUTHENTIK_ERROR_REPORTING__ENABLED
|
||||||
- AUTHENTIK_SECRET_KEY=file:///run/secrets/secret_key
|
- AUTHENTIK_SECRET_KEY= #file:///run/secrets/secret_key
|
||||||
|
- AK_ADMIN_TOKEN= #file:///run/secrets/admin_token
|
||||||
|
- AK_ADMIN_PASS= #file:///run/secrets/admin_pass
|
||||||
- AUTHENTIK_EMAIL__HOST
|
- AUTHENTIK_EMAIL__HOST
|
||||||
- AUTHENTIK_EMAIL__PORT
|
- AUTHENTIK_EMAIL__PORT
|
||||||
- AUTHENTIK_EMAIL__USERNAME
|
- AUTHENTIK_EMAIL__USERNAME
|
||||||
- AUTHENTIK_EMAIL__PASSWORD=file:///run/secrets/email_pass
|
- AUTHENTIK_EMAIL__PASSWORD
|
||||||
- AUTHENTIK_EMAIL__USE_TLS
|
- AUTHENTIK_EMAIL__USE_TLS
|
||||||
- AUTHENTIK_EMAIL__USE_SSL
|
- AUTHENTIK_EMAIL__USE_SSL
|
||||||
- AUTHENTIK_EMAIL__TIMEOUT
|
- AUTHENTIK_EMAIL__TIMEOUT
|
||||||
@ -20,31 +22,28 @@ x-env: &env
|
|||||||
- AUTHENTIK_SETTINGS__THEME__BACKGROUND
|
- AUTHENTIK_SETTINGS__THEME__BACKGROUND
|
||||||
- AUTHENTIK_COLOR_BACKGROUND_LIGHT
|
- AUTHENTIK_COLOR_BACKGROUND_LIGHT
|
||||||
- AUTHENTIK_FOOTER_LINKS
|
- AUTHENTIK_FOOTER_LINKS
|
||||||
- AUTHENTIK_IMPERSONATION
|
|
||||||
- WELCOME_MESSAGE
|
- WELCOME_MESSAGE
|
||||||
- DEFAULT_LANGUAGE
|
- DEFAULT_LANGUAGE
|
||||||
- EMAIL_SUBJECT
|
|
||||||
- EMAIL_TOKEN_EXPIRY_MINUTES
|
|
||||||
- DOMAIN
|
- DOMAIN
|
||||||
- LOGOUT_REDIRECT
|
|
||||||
|
|
||||||
version: '3.8'
|
version: '3.8'
|
||||||
services:
|
services:
|
||||||
app:
|
app:
|
||||||
image: ghcr.io/goauthentik/server:2023.2.3
|
image: ghcr.io/goauthentik/server:2022.10.1
|
||||||
command: server
|
command: server
|
||||||
secrets:
|
# secrets:
|
||||||
- db_password
|
# - db_password
|
||||||
- admin_pass
|
# - admin_pass
|
||||||
- admin_token
|
# - admin_token
|
||||||
- secret_key
|
# - secret_key
|
||||||
- email_pass
|
|
||||||
volumes:
|
volumes:
|
||||||
- media:/media
|
- media:/media
|
||||||
- custom-templates:/templates
|
- custom-templates:/templates
|
||||||
configs:
|
configs:
|
||||||
- source: custom_css
|
- source: custom_css
|
||||||
target: /web/dist/custom.css
|
target: /web/dist/custom.css
|
||||||
|
- source: recovery_template_de
|
||||||
|
target: /templates/password_reset_de.html
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
- proxy
|
- proxy
|
||||||
@ -71,17 +70,16 @@ services:
|
|||||||
- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
|
- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
|
||||||
- "traefik.http.middlewares.${STACK_NAME}-frameOptions.headers.customFrameOptionsValue=SAMEORIGIN"
|
- "traefik.http.middlewares.${STACK_NAME}-frameOptions.headers.customFrameOptionsValue=SAMEORIGIN"
|
||||||
- "traefik.http.middlewares.${STACK_NAME}-frameOptions.headers.contentSecurityPolicy=frame-ancestors ${X_FRAME_OPTIONS_ALLOW_FROM}"
|
- "traefik.http.middlewares.${STACK_NAME}-frameOptions.headers.contentSecurityPolicy=frame-ancestors ${X_FRAME_OPTIONS_ALLOW_FROM}"
|
||||||
- "coop-cloud.${STACK_NAME}.version=1.4.2+2023.2.3"
|
- "coop-cloud.${STACK_NAME}.version=0.6.0+2022.10.1"
|
||||||
|
|
||||||
worker:
|
worker:
|
||||||
image: ghcr.io/goauthentik/server:2023.2.3
|
image: ghcr.io/goauthentik/server:2022.10.1
|
||||||
command: worker
|
command: worker
|
||||||
secrets:
|
# secrets:
|
||||||
- db_password
|
# - db_password
|
||||||
- admin_pass
|
# - admin_pass
|
||||||
- admin_token
|
# - admin_token
|
||||||
- secret_key
|
# - secret_key
|
||||||
- email_pass
|
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
- proxy
|
- proxy
|
||||||
@ -92,16 +90,15 @@ services:
|
|||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
- custom-templates:/templates
|
- custom-templates:/templates
|
||||||
- /dev/null:/blueprints/default/10-flow-default-authentication-flow.yaml
|
- /dev/null:/blueprints/default/10-flow-default-authentication-flow.yaml
|
||||||
- /dev/null:/blueprints/default/10-flow-default-invalidation-flow.yaml
|
|
||||||
configs:
|
configs:
|
||||||
- source: custom_flows
|
- source: custom_flows
|
||||||
target: /blueprints/custom_flows.yaml
|
target: /blueprints/custom_flows.yaml
|
||||||
environment: *env
|
environment: *env
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: postgres:12.14-alpine
|
image: postgres:12.12-alpine
|
||||||
secrets:
|
# secrets:
|
||||||
- db_password
|
# - db_password
|
||||||
volumes:
|
volumes:
|
||||||
- database:/var/lib/postgresql/data
|
- database:/var/lib/postgresql/data
|
||||||
networks:
|
networks:
|
||||||
@ -113,18 +110,18 @@ services:
|
|||||||
retries: 10
|
retries: 10
|
||||||
start_period: 1m
|
start_period: 1m
|
||||||
environment:
|
environment:
|
||||||
- POSTGRES_PASSWORD_FILE=/run/secrets/db_password
|
- POSTGRES_PASSWORD
|
||||||
- POSTGRES_USER=${AUTHENTIK_POSTGRESQL__USER}
|
- POSTGRES_USER
|
||||||
- POSTGRES_DB=${AUTHENTIK_POSTGRESQL__NAME}
|
- POSTGRES_DB
|
||||||
deploy:
|
deploy:
|
||||||
labels:
|
labels:
|
||||||
backupbot.backup: "true"
|
backupbot.backup: "true"
|
||||||
backupbot.backup.pre-hook: "mkdir -p /tmp/backup/ && PGPASSWORD=$$(cat /run/secrets/db_password) pg_dump -U $${POSTGRES_USER} $${POSTGRES_DB} > /tmp/backup/backup.sql"
|
backupbot.backup.pre-hook: "mkdir -p /tmp/backup/ && PGPASSWORD=${POSTGRES_PASSWORD} pg_dump -U ${POSTGRES_USER} ${POSTGRES_DB} > /tmp/backup/backup.sql"
|
||||||
backupbot.backup.post-hook: "rm -rf /tmp/backup"
|
backupbot.backup.post-hook: "rm -rf /tmp/backup"
|
||||||
backupbot.backup.path: "/tmp/backup/"
|
backupbot.backup.path: "/tmp/backup/"
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
image: redis:7.0.9-alpine
|
image: redis:7.0.5-alpine
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
healthcheck:
|
healthcheck:
|
||||||
@ -134,22 +131,19 @@ services:
|
|||||||
retries: 10
|
retries: 10
|
||||||
start_period: 1m
|
start_period: 1m
|
||||||
|
|
||||||
secrets:
|
# secrets:
|
||||||
db_password:
|
# db_password:
|
||||||
external: true
|
# external: true
|
||||||
name: ${STACK_NAME}_db_password_${SECRET_DB_PASSWORD_VERSION}
|
# name: ${STACK_NAME}_db_password
|
||||||
secret_key:
|
# secret_key:
|
||||||
external: true
|
# external: true
|
||||||
name: ${STACK_NAME}_secret_key_${SECRET_SECRET_KEY_VERSION}
|
# name: ${STACK_NAME}_secret_key_${SECRET_SECRET_KEY_VERSION}
|
||||||
admin_token:
|
# admin_token:
|
||||||
external: true
|
# external: true
|
||||||
name: ${STACK_NAME}_admin_token_${SECRET_ADMIN_TOKEN_VERSION}
|
# name: ${STACK_NAME}_admin_token_${SECRET_ADMIN_TOKEN_VERSION}
|
||||||
admin_pass:
|
# admin_pass:
|
||||||
external: true
|
# external: true
|
||||||
name: ${STACK_NAME}_admin_pass_${SECRET_ADMIN_PASS_VERSION}
|
# name: ${STACK_NAME}_admin_pass_${SECRET_ADMIN_PASS_VERSION}
|
||||||
email_pass:
|
|
||||||
external: true
|
|
||||||
name: ${STACK_NAME}_email_pass_${SECRET_EMAIL_PASS_VERSION}
|
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
proxy:
|
proxy:
|
||||||
@ -167,6 +161,9 @@ configs:
|
|||||||
name: ${STACK_NAME}_custom_css_${CUSTOM_CSS_VERSION}
|
name: ${STACK_NAME}_custom_css_${CUSTOM_CSS_VERSION}
|
||||||
file: custom.css.tmpl
|
file: custom.css.tmpl
|
||||||
template_driver: golang
|
template_driver: golang
|
||||||
|
recovery_template_de:
|
||||||
|
name: ${STACK_NAME}_recovery_template_de_${RECOVERY_TEMPLATE_DE_VERSION}
|
||||||
|
file: password_reset_de.html
|
||||||
custom_flows:
|
custom_flows:
|
||||||
name: ${STACK_NAME}_custom_flows_${CUSTOM_FLOWS_VERSION}
|
name: ${STACK_NAME}_custom_flows_${CUSTOM_FLOWS_VERSION}
|
||||||
file: custom_flows.yaml.tmpl
|
file: custom_flows.yaml.tmpl
|
||||||
|
@ -10,6 +10,7 @@ context:
|
|||||||
transl_password_repeat: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Passwort (wiederholen) {{ else }} Password (repeat) {{ end }}
|
transl_password_repeat: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Passwort (wiederholen) {{ else }} Password (repeat) {{ end }}
|
||||||
transl_username: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Benutzername {{ else }} Username {{ end }}
|
transl_username: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Benutzername {{ else }} Username {{ end }}
|
||||||
transl_name: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Vor- und Nachname {{ else }} Full name {{ end }}
|
transl_name: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} Vor- und Nachname {{ else }} Full name {{ end }}
|
||||||
|
transl_template_recovery: {{ if eq (env "DEFAULT_LANGUAGE") "de" }} password_reset_de.html {{ else }} email/password_reset.html {{ end }}
|
||||||
|
|
||||||
entries:
|
entries:
|
||||||
######## Email Recovery Flow ########
|
######## Email Recovery Flow ########
|
||||||
@ -54,9 +55,9 @@ entries:
|
|||||||
model: authentik_stages_email.emailstage
|
model: authentik_stages_email.emailstage
|
||||||
attrs:
|
attrs:
|
||||||
use_global_settings: true
|
use_global_settings: true
|
||||||
token_expiry: {{ env "EMAIL_TOKEN_EXPIRY_MINUTES" }}
|
token_expiry: 30
|
||||||
subject: "{{ env "EMAIL_SUBJECT" }}"
|
subject: authentik
|
||||||
template: email/password_reset.html
|
template: !Context transl_template_recovery
|
||||||
activate_user_on_success: true
|
activate_user_on_success: true
|
||||||
- identifiers:
|
- identifiers:
|
||||||
name: default-recovery-user-write
|
name: default-recovery-user-write
|
||||||
@ -334,55 +335,6 @@ entries:
|
|||||||
target: !KeyOf invitation-enrollment-flow
|
target: !KeyOf invitation-enrollment-flow
|
||||||
model: authentik_flows.flowstagebinding
|
model: authentik_flows.flowstagebinding
|
||||||
|
|
||||||
######## Invalidation Flow ########
|
|
||||||
- identifiers:
|
|
||||||
slug: logout-flow
|
|
||||||
id: logout-flow
|
|
||||||
model: authentik_flows.flow
|
|
||||||
attrs:
|
|
||||||
name: Logout
|
|
||||||
title: Logout Flow
|
|
||||||
designation: invalidation
|
|
||||||
|
|
||||||
### STAGES
|
|
||||||
|
|
||||||
- id: logout-stage
|
|
||||||
identifiers:
|
|
||||||
name: logout-stage
|
|
||||||
model: authentik_stages_user_logout.userlogoutstage
|
|
||||||
|
|
||||||
### STAGE BINDINGS
|
|
||||||
|
|
||||||
- identifiers:
|
|
||||||
order: 0
|
|
||||||
stage: !KeyOf logout-stage
|
|
||||||
target: !KeyOf logout-flow
|
|
||||||
model: authentik_flows.flowstagebinding
|
|
||||||
attrs:
|
|
||||||
re_evaluate_policies: true
|
|
||||||
id: logout-stage-binding
|
|
||||||
|
|
||||||
### POLICIES
|
|
||||||
- attrs:
|
|
||||||
execution_logging: true
|
|
||||||
expression: 'context[''flow_plan''].context[''redirect''] = ''{{ env "LOGOUT_REDIRECT" }}''
|
|
||||||
|
|
||||||
return True'
|
|
||||||
identifiers:
|
|
||||||
name: redirect-policy
|
|
||||||
id: redirect-policy
|
|
||||||
model: authentik_policies_expression.expressionpolicy
|
|
||||||
|
|
||||||
### POLICY BINDINGS
|
|
||||||
- identifiers:
|
|
||||||
policy: !KeyOf redirect-policy
|
|
||||||
target: !KeyOf logout-stage-binding
|
|
||||||
order: 0
|
|
||||||
model: authentik_policies.policybinding
|
|
||||||
attrs:
|
|
||||||
enabled: {{ if eq (env "LOGOUT_REDIRECT") "" }} false {{ else }} true {{ end }}
|
|
||||||
timeout: 30
|
|
||||||
|
|
||||||
######## System Tenant ##########
|
######## System Tenant ##########
|
||||||
- attrs:
|
- attrs:
|
||||||
attributes:
|
attributes:
|
||||||
@ -396,7 +348,7 @@ entries:
|
|||||||
# event_retention: days=365
|
# event_retention: days=365
|
||||||
flow_authentication: !KeyOf authentication_flow
|
flow_authentication: !KeyOf authentication_flow
|
||||||
flow_recovery: !KeyOf recovery_flow
|
flow_recovery: !KeyOf recovery_flow
|
||||||
flow_invalidation: !KeyOf logout-flow
|
flow_invalidation: !Find [authentik_flows.flow, [slug, default-invalidation-flow]]
|
||||||
flow_user_settings: !Find [authentik_flows.flow, [slug, default-user-settings-flow]]
|
flow_user_settings: !Find [authentik_flows.flow, [slug, default-user-settings-flow]]
|
||||||
identifiers:
|
identifiers:
|
||||||
pk: 047cce25-aae2-4b02-9f96-078e155f803d
|
pk: 047cce25-aae2-4b02-9f96-078e155f803d
|
||||||
|
53
password_reset_de.html
Normal file
53
password_reset_de.html
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
{% extends "email/base.html" %}
|
||||||
|
|
||||||
|
{% load i18n %}
|
||||||
|
{% load humanize %}
|
||||||
|
|
||||||
|
{% block content %}
|
||||||
|
<tr>
|
||||||
|
<td class="alert alert-success">
|
||||||
|
{% blocktrans with username=user.username %}
|
||||||
|
Herzlich Willkommen {{ username }},
|
||||||
|
{% endblocktrans %}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="content-wrap">
|
||||||
|
<table width="100%" cellpadding="0" cellspacing="0">
|
||||||
|
<tr>
|
||||||
|
<td class="content-block">
|
||||||
|
{% blocktrans %}
|
||||||
|
Klicke auf folgenden Link um ein Passwort für deinen Account zu erstellen:
|
||||||
|
{% endblocktrans %}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="content-block">
|
||||||
|
<table role="presentation" border="0" cellpadding="0" cellspacing="0" class="btn btn-primary">
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td align="center">
|
||||||
|
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td> <a id="confirm" href="{{ url }}" rel="noopener noreferrer" target="_blank">Passwort Erstellen</a> </td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="content-block">
|
||||||
|
{% blocktrans with expires=expires|naturaltime %}
|
||||||
|
Falls du diese E-Mail fälschlicherweise erhalten hast, ignoriere sie bitte. Der obige Link ist gültig für: {{ expires }}.
|
||||||
|
{% endblocktrans %}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{% endblock %}
|
@ -1,15 +0,0 @@
|
|||||||
This upgrade replaces the passwords stored in env variables by docker secrets.
|
|
||||||
You need to insert the following passwords as secret:
|
|
||||||
|
|
||||||
`POSTGRES_PASSWORD` / `AUTHENTIK_POSTGRESQL__PASSWORD`:
|
|
||||||
`abra app secret insert <app_name> db_password v1 <password>`
|
|
||||||
`AUTHENTIK_SECRET_KEY`:
|
|
||||||
`abra app secret insert <app_name> secret_key v1 <password>`
|
|
||||||
`AK_ADMIN_TOKEN`:
|
|
||||||
`abra app secret insert <app_name> admin_token v1 <password>`
|
|
||||||
`AK_ADMIN_PASS`:
|
|
||||||
`abra app secret insert <app_name> admin_pass v1 <password>`
|
|
||||||
`AUTHENTIK_EMAIL__PASSWORD`:
|
|
||||||
`abra app secret insert <app_name> email_pass v1 <password>`
|
|
||||||
|
|
||||||
These variables should be removed from the .env file.
|
|
@ -1 +0,0 @@
|
|||||||
Logout URL changes from `https://login.example.org/if/flow/default-invalidation-flow/` to `https://login.example.org/if/flow/logout-flow/`
|
|
Reference in New Issue
Block a user