| 1 | # A container for all things Data, be sure to set a secret password for discourse account, SOME_SECRET is just an example |
| 2 | # |
| 3 | templates: |
| 4 | - "templates/cron.template.yml" |
| 5 | - "templates/syslog.template.yml" |
| 6 | - "templates/postgres.template.yml" |
| 7 | - "templates/redis.template.yml" |
| 8 | - "templates/sshd.template.yml" |
| 9 | |
| 10 | expose: |
| 11 | - "5432:5432" |
| 12 | - "6379:6379" |
| 13 | - "2221:22" |
| 14 | |
| 15 | env: |
| 16 | # ensure locale exists in container, you may need to install it |
| 17 | LANG: en_US.UTF-8 |
| 18 | |
| 19 | # amend SOME_SECRET to a password for the discourse user |
| 20 | hooks: |
| 21 | after_postgres: |
| 22 | - exec: |
| 23 | stdin: | |
| 24 | alter user discourse with password 'SOME_SECRET'; |
| 25 | cmd: sudo -u postgres psql discourse |
| 26 | raise_on_fail: false |
| 27 | # be sure to set the host location somewhere sane |
| 28 | volumes: |
| 29 | - volume: |
| 30 | host: /var/docker/shared |
| 31 | guest: /shared |