WIP authelia

Update everything
This commit is contained in:
Marc Fokkert
2025-02-25 10:18:06 +01:00
parent 6fa1a1dbb2
commit 8106122d0a
3 changed files with 510 additions and 289 deletions

47
authelia.tf Normal file
View File

@@ -0,0 +1,47 @@
data "docker_registry_image" "authelia" {
name = "authelia/authelia:latest"
}
resource "docker_image" "authelia" {
name = data.docker_registry_image.authelia.name
pull_triggers = [data.docker_registry_image.authelia.sha256_digest]
}
resource "docker_container" "authelia" {
image = docker_image.authelia.image_id
name = "authelia"
restart = "always"
log_driver = "local"
env = [
"AUTHELIA_IDENTITY_VALIDATION_RESET_PASSWORD_JWT_SECRET_FILE=/secrets/JWT_SECRET",
"AUTHELIA_SESSION_SECRET_FILE=/secrets/SESSION_SECRET",
"AUTHELIA_STORAGE_POSTGRES_PASSWORD_FILE=/secrets/STORAGE_PASSWORD",
"AUTHELIA_STORAGE_ENCRYPTION_KEY_FILE=/secrets/STORAGE_ENCRYPTION_KEY"
]
networks_advanced {
name = docker_network.bridge.name
ipv4_address = "192.168.2.151"
}
mounts {
target = "/config"
source = "/share/appdata/authelia/config"
type = "bind"
}
mounts {
target = "/secrets"
source = "/share/appdata/authelia/secrets"
type = "bind"
}
lifecycle {
ignore_changes = [
ulimit,
log_opts
]
}
}