Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 1 | version: "3" |
| 2 | services: |
| 3 | nginx: |
Nico Huber | 38c14da | 2023-06-24 16:59:28 +0000 | [diff] [blame] | 4 | build: |
| 5 | context: . |
| 6 | dockerfile: nginx/Dockerfile |
Nico Huber | aa15aee | 2023-07-01 22:35:45 +0000 | [diff] [blame] | 7 | args: |
| 8 | - SELFSIGNED_REQ_HOST=${SA_PUBLIC_DOMAIN_NAME} |
| 9 | - SELFSIGNED_REQ_ALT_NAMES=DNS:${SA_PUBLIC_DOMAIN_NAME}, |
| 10 | DNS:id.${SA_PUBLIC_DOMAIN_NAME}, DNS:mail.${SA_PUBLIC_DOMAIN_NAME}, |
| 11 | DNS:review.${SA_PUBLIC_DOMAIN_NAME} |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 12 | env_file: environment |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 13 | ports: |
| 14 | - "80:80" |
Nico Huber | 38c14da | 2023-06-24 16:59:28 +0000 | [diff] [blame] | 15 | - "443:443" |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 16 | networks: |
| 17 | - simpleidnet |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 18 | - gerritnet |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 19 | volumes: |
Nico Huber | 15edd77 | 2023-07-01 18:16:50 +0000 | [diff] [blame] | 20 | - ./certbot/www/:/var/www/certbot/:ro |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 21 | - ./simpleid/identities/:/var/db/simpleid-templates/:ro |
| 22 | - ./simpleid/www/:/var/www/simpleid/:ro |
Nico Huber | 15edd77 | 2023-07-01 18:16:50 +0000 | [diff] [blame] | 23 | - ./certs/:/etc/nginx/certs/:rw |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 24 | - ./nginx/sa.conf:/etc/nginx/conf.d/sa.conf.template:ro |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 25 | - ./nginx/empty.conf:/etc/nginx/conf.d/default.conf:ro |
| 26 | - ./logs/nginx:/var/log/nginx/:rw |
Nico Huber | 5d7a1cb | 2023-07-23 19:36:14 +0000 | [diff] [blame^] | 27 | postgres: |
| 28 | build: |
| 29 | context: ./postgres/docker/ |
| 30 | networks: |
| 31 | - dbnet |
| 32 | volumes: |
| 33 | - ./postgres/postgres.conf:/etc/postgresql/postgresql.conf:ro |
| 34 | - ./postgres/init.sh:/docker-entrypoint-initdb.d/init.sh:ro |
| 35 | - ./postgres/data/:/var/lib/postgresql/data/:rw |
| 36 | - ./postgres/passwd/:/tmp/passwd/:rw |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 37 | simpleid: |
| 38 | build: |
| 39 | context: . |
| 40 | dockerfile: simpleid/Dockerfile |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 41 | env_file: environment |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 42 | networks: |
| 43 | - simpleidnet |
| 44 | volumes: |
| 45 | - ./simpleid/cache/:/var/cache/simpleid/:rw |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 46 | - ./simpleid/identities/:/var/db/simpleid-templates/:ro |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 47 | - ./simpleid/store/:/var/lib/simpleid/:rw |
Nico Huber | d652872 | 2023-07-01 14:38:39 +0000 | [diff] [blame] | 48 | - ./simpleid/www/:/var/www/simpleid/:ro |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 49 | - ./logs/simpleid/:/var/log/:rw |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 50 | gerrit: |
| 51 | build: |
| 52 | context: . |
| 53 | dockerfile: gerrit/Dockerfile |
Nico Huber | b650ed4 | 2023-07-20 17:08:54 +0000 | [diff] [blame] | 54 | hostname: review.${SA_PUBLIC_DOMAIN_NAME} |
| 55 | env_file: |
| 56 | - gerrit/environment |
| 57 | - environment |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 58 | environment: |
Nico Huber | b650ed4 | 2023-07-20 17:08:54 +0000 | [diff] [blame] | 59 | - GERRIT_USER_EMAIL=gerrit@${SA_PUBLIC_DOMAIN_NAME} |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 60 | - HTTPD_LISTEN_URL=proxy-https://*:8080/ |
Nico Huber | 3c7f1c0 | 2023-07-20 17:18:51 +0000 | [diff] [blame] | 61 | ports: |
| 62 | - "29418:29418" |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 63 | networks: |
| 64 | - gerritnet |
| 65 | volumes: |
| 66 | - ./logs/gerrit/:/var/gerrit/logs/:rw |
Nico Huber | b650ed4 | 2023-07-20 17:08:54 +0000 | [diff] [blame] | 67 | - ./mail/passwd/gerrit/:/var/gerrit/passwd/:rw |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 68 | - ./gerrit/etc/:/var/gerrit/etc/:rw |
| 69 | - ./gerrit/db/:/var/gerrit/db/:rw |
| 70 | - ./gerrit/git/:/var/gerrit/git/:rw |
| 71 | - ./gerrit/index/:/var/gerrit/index/:rw |
| 72 | - ./gerrit/cache/:/var/gerrit/cache/:rw |
Nico Huber | 5407310 | 2023-06-25 11:36:59 +0000 | [diff] [blame] | 73 | - ./gerrit/gerrit-oauth-provider.jar:/var/gerrit/plugins/gerrit-oauth-provider.jar:ro |
Nico Huber | 804b41b | 2023-07-02 15:53:42 +0000 | [diff] [blame] | 74 | mailserver: |
| 75 | image: ghcr.io/docker-mailserver/docker-mailserver:12 |
| 76 | #container_name: mailserver |
| 77 | # Provide the FQDN of your mail server here (Your DNS MX record should point to this value) |
| 78 | hostname: mail.${SA_PUBLIC_DOMAIN_NAME} |
| 79 | env_file: mail/mailserver.env |
| 80 | # More information about the mail-server ports: |
| 81 | # https://docker-mailserver.github.io/docker-mailserver/latest/config/security/understanding-the-ports/ |
| 82 | # To avoid conflicts with yaml base-60 float, DO NOT remove the quotation marks. |
| 83 | ports: |
| 84 | - "25:25" # SMTP (explicit TLS => STARTTLS) |
| 85 | - "143:143" # IMAP4 (explicit TLS => STARTTLS) |
| 86 | - "465:465" # ESMTP (implicit TLS) |
| 87 | - "587:587" # ESMTP (explicit TLS => STARTTLS) |
| 88 | - "993:993" # IMAP4 (implicit TLS) |
Nico Huber | b650ed4 | 2023-07-20 17:08:54 +0000 | [diff] [blame] | 89 | networks: |
| 90 | - gerritnet |
Nico Huber | 804b41b | 2023-07-02 15:53:42 +0000 | [diff] [blame] | 91 | volumes: |
| 92 | - ./logs/mail-supervisor/:/var/log/supervisor/:rw |
| 93 | - ./logs/mail/:/var/log/mail/:rw |
Nico Huber | 49781a7 | 2023-07-02 16:29:22 +0000 | [diff] [blame] | 94 | - ./certs/:/etc/letsencrypt/:ro |
Nico Huber | b650ed4 | 2023-07-20 17:08:54 +0000 | [diff] [blame] | 95 | - ./mail/passwd/:/tmp/passwd/:ro |
Nico Huber | 804b41b | 2023-07-02 15:53:42 +0000 | [diff] [blame] | 96 | - ./mail/data/:/var/mail/:rw |
| 97 | - ./mail/state/:/var/mail-state/:rw |
| 98 | - ./mail/config/:/tmp/docker-mailserver/:rw |
Nico Huber | 22aecea | 2023-07-19 01:39:58 +0000 | [diff] [blame] | 99 | - ./mail/rspamd-override.d/:/etc/rspamd/override.d/:rw |
Nico Huber | 804b41b | 2023-07-02 15:53:42 +0000 | [diff] [blame] | 100 | - /etc/localtime:/etc/localtime:ro |
| 101 | restart: always |
| 102 | stop_grace_period: 1m |
| 103 | # Uncomment if using `ENABLE_FAIL2BAN=1`: |
| 104 | # cap_add: |
| 105 | # - NET_ADMIN |
| 106 | healthcheck: |
| 107 | test: "ss --listening --tcp | grep -P 'LISTEN.+:smtp' || exit 1" |
| 108 | timeout: 3s |
| 109 | retries: 0 |
Nico Huber | 8cd50ee | 2023-06-24 15:35:16 +0000 | [diff] [blame] | 110 | networks: |
| 111 | simpleidnet: |
| 112 | driver: bridge |
Nico Huber | 4bc2bdd | 2023-07-01 22:33:36 +0000 | [diff] [blame] | 113 | ipam: |
| 114 | config: |
| 115 | - subnet: 10.12.14.16/29 |
Nico Huber | a1a296f | 2023-06-25 10:07:07 +0000 | [diff] [blame] | 116 | gerritnet: |
| 117 | driver: bridge |
Nico Huber | 4bc2bdd | 2023-07-01 22:33:36 +0000 | [diff] [blame] | 118 | ipam: |
| 119 | config: |
| 120 | - subnet: 10.12.14.24/29 |
Nico Huber | 5d7a1cb | 2023-07-23 19:36:14 +0000 | [diff] [blame^] | 121 | dbnet: |
| 122 | driver: bridge |
| 123 | ipam: |
| 124 | config: |
| 125 | - subnet: 10.12.14.40/29 |