chore(bitwarden): extract container env vars

This commit is contained in:
Jan Christian Grünhage 2021-09-04 10:42:19 +02:00 committed by Johanna Dorothea Reichmann
parent 2372548767
commit 1ab505d0b2
No known key found for this signature in database
GPG key ID: 03624C433676E465
2 changed files with 18 additions and 10 deletions

View file

@ -8,3 +8,20 @@ bitwarden_yubico_client_id:
bitwarden_yubico_secret_key:
bitwarden_smtp_pass:
bitwarden_domain:
# TODO: move to playbook
bitwarden_smtp_host: "171.17.0.1"
bitwarden_smtp_from: "pass@famedly.com"
bitwarden_smtp_port: "2524"
bitwarden_smtp_ssl: "false"
bitwarden_env_vars:
DOMAIN: "https://{{ bitwarden_domain }}"
SIGNUPS_ALLOWED: "false"
ADMIN_TOKEN: "{{ bitwarden_admin_token }}"
YUBICO_CLIENT_ID: "{{ bitwarden_yubico_client_id }}"
YUBICO_SECRET_KEY: "{{ bitwarden_yubico_secret_key }}"
SMTP_HOST: "{{ bitwarden_smtp_host }}"
SMTP_FROM: "{{ bitwarden_smtp_from }}"
SMTP_PORT: "{{ bitwarden_smtp_port }}"
SMTP_SSL: "{{ bitwarden_smtp_ssl }}"

View file

@ -10,16 +10,7 @@
image: "{{ bitwarden_container_image }}"
name: bitwarden
labels: "{{ bitwarden_docker_labels_complete }}"
env:
DOMAIN: "https://{{ bitwarden_domain }}"
SIGNUPS_ALLOWED: "false"
ADMIN_TOKEN: "{{ bitwarden_admin_token }}"
YUBICO_CLIENT_ID: "{{ bitwarden_yubico_client_id }}"
YUBICO_SECRET_KEY: "{{ bitwarden_yubico_secret_key }}"
SMTP_HOST: "172.17.0.1"
SMTP_FROM: "pass@famedly.com"
SMTP_PORT: "2525"
SMTP_SSL: "false"
env: "{{ bitwarden_env_vars }}"
volumes:
- "{{ bitwarden_home }}:/data"
restart_policy: unless-stopped