2019-02-13 20:16:36 +00:00
|
|
|
---
|
|
|
|
|
|
|
|
- name: codimd network
|
|
|
|
docker_network:
|
|
|
|
name: codimd
|
|
|
|
|
|
|
|
- name: create codimd volume folders
|
|
|
|
file:
|
|
|
|
name: "{{ codimd.volume_folder }}/{{ volume }}"
|
|
|
|
state: directory
|
|
|
|
loop:
|
|
|
|
- "db"
|
|
|
|
- "codimd/uploads"
|
|
|
|
|
|
|
|
loop_control:
|
|
|
|
loop_var: volume
|
|
|
|
|
|
|
|
- name: codimd database container
|
|
|
|
docker_container:
|
|
|
|
name: codimd_db
|
|
|
|
image: postgres:10
|
|
|
|
state: started
|
|
|
|
restart_policy: unless-stopped
|
|
|
|
networks:
|
|
|
|
- name: codimd
|
|
|
|
volumes:
|
|
|
|
- "{{ codimd.volume_folder }}/db:/var/lib/postgresql/data"
|
|
|
|
env:
|
|
|
|
POSTGRES_USER: "codimd"
|
|
|
|
POSTGRES_PASSWORD: "{{ postgres_passwords.codimd }}"
|
|
|
|
|
|
|
|
- name: codimd app container
|
|
|
|
docker_container:
|
|
|
|
name: codimd_app
|
2019-03-05 09:06:10 +00:00
|
|
|
image: hackmdio/hackmd:1.3.0
|
2019-02-13 20:16:36 +00:00
|
|
|
restart_policy: unless-stopped
|
|
|
|
networks:
|
|
|
|
- name: codimd
|
|
|
|
- name: ldap
|
|
|
|
- name: external_services
|
|
|
|
volumes:
|
|
|
|
- "{{ codimd.volume_folder }}/codimd/uploads:/codimd/public/uploads"
|
|
|
|
|
|
|
|
env:
|
|
|
|
CMD_DB_URL: "postgres://codimd:{{ postgres_passwords.codimd }}@codimd_db:5432/codimd"
|
2019-02-28 07:22:38 +00:00
|
|
|
CMD_ALLOW_EMAIL_REGISTER: "False"
|
2019-02-13 20:16:36 +00:00
|
|
|
CMD_IMAGE_UPLOAD_TYPE: "filesystem"
|
2019-02-28 07:22:38 +00:00
|
|
|
CMD_EMAIL: "False"
|
2019-02-13 20:16:36 +00:00
|
|
|
CMD_LDAP_URL: "ldap://openldap"
|
2019-02-14 21:52:55 +00:00
|
|
|
CMD_LDAP_BINDDN: "cn=admin,dc=data,dc=coop"
|
2019-02-13 20:16:36 +00:00
|
|
|
CMD_LDAP_BINDCREDENTIALS: "{{ ldap_admin_password }}"
|
|
|
|
CMD_LDAP_SEARCHBASE: "dc=data,dc=coop"
|
2019-02-14 21:52:55 +00:00
|
|
|
CMD_LDAP_SEARCHFILTER: "(&(uid={{ '{{username}}' }})(objectClass=inetOrgPerson))"
|
2019-03-05 09:06:10 +00:00
|
|
|
CMD_USECDN: "false"
|
2019-02-13 20:16:36 +00:00
|
|
|
VIRTUAL_HOST: "{{ codimd.domain }}"
|
|
|
|
LETSENCRYPT_HOST: "{{ codimd.domain }}"
|
|
|
|
LETSENCRYPT_EMAIL: "{{ letsencrypt_email }}"
|