Initial import
This commit is contained in:
@@ -0,0 +1,163 @@
|
||||
name: simplelogin
|
||||
|
||||
x-simplelogin-image: &simplelogin-image
|
||||
image: simplelogin/app:4.6.5-beta
|
||||
|
||||
x-simplelogin-env: &simplelogin-env
|
||||
URL: https://alias.tinyhome.ndmv.net
|
||||
EMAIL_DOMAIN: tinyhome.ndmv.net
|
||||
SUPPORT_EMAIL: alias@postbox.tinyhome.ndmv.net
|
||||
EMAIL_SERVERS_WITH_PRIORITY: '[(10, "alias.tinyhome.ndmv.net.")]'
|
||||
DISABLE_ALIAS_SUFFIX: "1"
|
||||
DKIM_PRIVATE_KEY_PATH: /dkim.key
|
||||
GNUPGHOME: /sl/pgp
|
||||
LOCAL_FILE_UPLOAD: "1"
|
||||
POSTFIX_SERVER: simplelogin-postfix
|
||||
|
||||
x-simplelogin-volumes: &simplelogin-volumes
|
||||
- simplelogin_gpg:/sl/pgp
|
||||
- simplelogin_upload:/code/static/upload
|
||||
- ./.secrets/dkim-rsa.key:/dkim.key:ro
|
||||
- ./.secrets/dkim.pub.key:/dkim.pub.key:ro
|
||||
|
||||
networks:
|
||||
pflab_proxy:
|
||||
name: pflab_proxy
|
||||
|
||||
pflab_backend:
|
||||
name: pflab_backend
|
||||
|
||||
volumes:
|
||||
simplelogin_gpg:
|
||||
name: pflab_simplelogin_gpg
|
||||
driver: local
|
||||
|
||||
simplelogin_upload:
|
||||
name: pflab_simplelogin_uploads
|
||||
driver: local
|
||||
|
||||
services:
|
||||
|
||||
simplelogin-migration:
|
||||
<<: *simplelogin-image
|
||||
command: ["alembic", "upgrade", "head"]
|
||||
container_name: pflab-simplelogin-migration
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment: *simplelogin-env
|
||||
|
||||
volumes: *simplelogin-volumes
|
||||
networks:
|
||||
- pflab_backend
|
||||
|
||||
simplelogin-init:
|
||||
<<: *simplelogin-image
|
||||
command: ["python", "init_app.py"]
|
||||
container_name: pflab-simplelogin-init
|
||||
depends_on:
|
||||
simplelogin-migration:
|
||||
condition: service_completed_successfully
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment: *simplelogin-env
|
||||
|
||||
volumes: *simplelogin-volumes
|
||||
|
||||
networks:
|
||||
- pflab_backend
|
||||
|
||||
simplelogin-postfix:
|
||||
image: simplelogin/postfix:latest
|
||||
container_name: pflab-simplelogin-postfix
|
||||
restart: unless-stopped
|
||||
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment:
|
||||
ALIASES_DEFAULT_DOMAIN: tinyhome.ndmv.net
|
||||
DB_HOST: pflab-postgres
|
||||
DB_USER: simplelogin
|
||||
DB_NAME: simplelogin
|
||||
EMAIL_HANDLER_HOST: pflab-simplelogin-email
|
||||
LETSENCRYPT_EMAIL: alias@postbox.tinyhome.ndmv.net
|
||||
POSTFIX_FQDN: alias.tinyhome.ndmv.net
|
||||
SIMPLELOGIN_COMPATIBILITY_MODE: v4
|
||||
# If you want the postfix container to use certs managed elsewhere,
|
||||
# mount the files and uncomment these:
|
||||
# TLS_KEY_FILE: /tls/privkey.pem
|
||||
# TLS_CERT_FILE: /tls/fullchain.pem
|
||||
|
||||
ports:
|
||||
- "25:25"
|
||||
- "587:587"
|
||||
|
||||
networks:
|
||||
- pflab_backend
|
||||
|
||||
simplelogin:
|
||||
<<: [*simplelogin-image]
|
||||
container_name: pflab-simplelogin
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- simplelogin-postfix
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "curl -fsS http://localhost:7777 >/dev/null || exit 1"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 30s
|
||||
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment: *simplelogin-env
|
||||
|
||||
volumes: *simplelogin-volumes
|
||||
|
||||
networks:
|
||||
- pflab_proxy
|
||||
- pflab_backend
|
||||
|
||||
simplelogin-email:
|
||||
<<: [*simplelogin-image]
|
||||
container_name: pflab-simplelogin-email
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
simplelogin-init:
|
||||
condition: service_completed_successfully
|
||||
simplelogin-postfix:
|
||||
condition: service_healthy
|
||||
|
||||
command: python email_handler.py
|
||||
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment: *simplelogin-env
|
||||
|
||||
ports:
|
||||
- "127.0.0.1:20381:20381"
|
||||
|
||||
volumes: *simplelogin-volumes
|
||||
|
||||
networks:
|
||||
- pflab_backend
|
||||
|
||||
simplelogin-worker:
|
||||
<<: [*simplelogin-image]
|
||||
container_name: pflab-simplelogin-worker
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
simplelogin-init:
|
||||
condition: service_completed_successfully
|
||||
simplelogin-email:
|
||||
condition: service_started
|
||||
|
||||
command: python job_runner.py
|
||||
|
||||
env_file:
|
||||
- ./.secrets/.env
|
||||
environment: *simplelogin-env
|
||||
|
||||
volumes: *simplelogin-volumes
|
||||
|
||||
networks:
|
||||
- pflab_backend
|
||||
Reference in New Issue
Block a user