add variables to mount custom volumes

This commit is contained in:
Robert Kaussow 2020-01-20 13:38:01 +01:00
parent 0d7866f9ce
commit 7286c4243a
2 changed files with 19 additions and 0 deletions

View File

@ -8,6 +8,11 @@ bitwardenrs_restart_policy: on-failure
bitwardenrs_exposed_port: 80
bitwardenrs_exposed_ip: 127.0.0.1
bitwardenrs_extra_hosts: []
# @var bitwardenrs_volumes_extra:example: >
# bitwardenrs_volumes_extra:
# - /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem:/etc/ssl/certs/ca-certificates.crt:Z
# @end
bitwardenrs_volumes_extra: []
# @var bitwardenrs_memory_limit: $ "_unset_"
# @var bitwardenrs_memory_limit:example: $ "512m"
@ -90,6 +95,11 @@ bitwardenrs_ldap_container_name: bitwardenrs_ldap
bitwardenrs_ldap_version: latest
bitwardenrs_ldap_image: "xoxys/bitwardenrs_ldap:{{ bitwardenrs_ldap_version }}"
bitwardenrs_ldap_restart_policy: on-failure
# @var bitwardenrs_ldap_volumes_extra:example: >
# bitwardenrs_ldap_volumes_extra:
# - /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem:/etc/ssl/certs/ca-certificates.crt:Z
# @end
bitwardenrs_ldap_volumes_extra: []
# @var bitwardenrs_ldap_memory_limit: $ "_unset_"
# @var bitwardenrs_ldap_memory_limit:example: $ "512m"

View File

@ -11,6 +11,9 @@ services:
- {{ bitwardenrs_exposed_ip + ':' if bitwardenrs_exposed_ip is defined else '' }}{{ bitwardenrs_exposed_port }}:8080
volumes:
- data:/app/data
{% for volume in bitwardenrs_volumes_extra %}
- {{ volume }}
{% endfor %}
{% if bitwardenrs_extra_hosts | default([]) %}
extra_hosts:
{% for host in bitwardenrs_extra_hosts %}
@ -104,6 +107,12 @@ services:
container_name: {{ bitwardenrs_ldap_container_name }}
image: {{ bitwardenrs_ldap_image }}
restart: {{ bitwardenrs_ldap_restart_policy }}
{% if bitwardenrs_ldap_volumes_extra %}
volumes:
{% for volume in bitwardenrs_ldap_volumes_extra %}
- {{ volume }}
{% endfor %}
{% end %}
environment:
- BITWARDENRS_LDAP_BITWARDEN_URL={{ bitwardenrs_ldap_bitwarden_url }}
- BITWARDENRS_LDAP_BITWARDEN_ADMIN_TOKEN={{ bitwardenrs_ldap_bitwarden_admin_token }}