Migrate HedgeDoc to Podman

This commit is contained in:
Viyurz 2024-10-14 15:31:36 +02:00
parent 31cf807758
commit c3f82875be
Signed by: Viyurz
SSH key fingerprint: SHA256:IskOHTmhHSJIvAt04N6aaxd5SZCVWW1Guf9tEcxIMj8
3 changed files with 37 additions and 0 deletions

View file

@ -0,0 +1,20 @@
CMD_DB_DIALECT=postgres
CMD_DB_HOST='postgres.${env["domain"]}'
CMD_DB_DATABASE=hedgedoc
CMD_DB_USERNAME='${secrets["postgres"]["hedgedoc"]["user"]}'
CMD_DB_PASSWORD='${secrets["postgres"]["hedgedoc"]["pass"]}'
CMD_DOMAIN='hedgedoc.${env["domain"]}'
CMD_PROTOCOL_USESSL=true
CMD_SESSION_SECRET='${secrets["hedgedoc_session"]}'
CMD_EMAIL=false
CMD_OAUTH2_PROVIDERNAME=Keycloak
CMD_OAUTH2_CLIENT_ID='${secrets["keycloak"]["hedgedoc"]["id"]}'
CMD_OAUTH2_CLIENT_SECRET='${secrets["keycloak"]["hedgedoc"]["secret"]}'
CMD_OAUTH2_AUTHORIZATION_URL=https://kc.${env["domain"]}/realms/master/protocol/openid-connect/auth
CMD_OAUTH2_TOKEN_URL=https://kc.${env["domain"]}/realms/master/protocol/openid-connect/token
CMD_OAUTH2_USER_PROFILE_URL=https://kc.${env["domain"]}/realms/master/protocol/openid-connect/userinfo
CMD_OAUTH2_SCOPE=openid email profile
CMD_OAUTH2_USER_PROFILE_USERNAME_ATTR=preferred_username
CMD_OAUTH2_USER_PROFILE_DISPLAY_NAME_ATTR=name
CMD_OAUTH2_USER_PROFILE_EMAIL_ATTR=email

View file

@ -0,0 +1,12 @@
services:
hedgedoc:
container_name: hedgedoc
image: quay.io/hedgedoc/hedgedoc:1.10.0-alpine
network_mode: pasta:-a,${env['pasta']['hedgedoc']['ipv4']},-a,${env['pasta']['hedgedoc']['ipv6']}
restart: always
user: ${env['users']['hedgedoc']}:${env['users']['hedgedoc']}
env_file: .env.rendered
ports:
- 127.0.0.1:${env['ports']['hedgedoc']}:3000
volumes:
- ${env['volumes']['hedgedoc']['uploadsdir']}:/hedgedoc/public/uploads

View file

@ -23,6 +23,8 @@ socket: "/run/podman/podman.sock"
backup: backup:
etebase: etebase:
- /mnt/etebasedata/media - /mnt/etebasedata/media
hedgedoc:
- /mnt/hedgedocuploads
synapse: synapse:
- /mnt/synapsedata - /mnt/synapsedata
vaultwarden: vaultwarden:
@ -53,6 +55,9 @@ pasta:
etebase: etebase:
ipv4: 10.86.5.1 ipv4: 10.86.5.1
ipv6: fc86::5 ipv6: fc86::5
hedgedoc:
ipv4: 10.86.8.1
ipv6: fc86::8
synapse: synapse:
ipv4: 10.86.19.1 ipv4: 10.86.19.1
ipv6: fc86::19 ipv6: fc86::19