forked from data.coop/ansible
Some mailman stuff.
This commit is contained in:
parent
1f69fdc3b4
commit
824bc583a1
68
roles/docker/tasks/services/mailman.yml
Normal file
68
roles/docker/tasks/services/mailman.yml
Normal file
|
@ -0,0 +1,68 @@
|
|||
---
|
||||
|
||||
- name: run mailman server containers
|
||||
docker_service:
|
||||
definition:
|
||||
version: '2'
|
||||
|
||||
services:
|
||||
mailman-core:
|
||||
image: maxking/mailman-core:0.2
|
||||
container_name: mailman-core
|
||||
hostname: mailman-core
|
||||
volumes:
|
||||
- /opt/mailman/core:/opt/mailman/
|
||||
stop_grace_period: 30s
|
||||
links:
|
||||
- database:database
|
||||
depends_on:
|
||||
- database
|
||||
environment:
|
||||
- DATABASE_URL=postgres://mailman:mailmanpass@database/mailmandb
|
||||
- DATABASE_TYPE=postgres
|
||||
- DATABASE_CLASS=mailman.database.postgresql.PostgreSQLDatabase
|
||||
- HYPERKITTY_API_KEY={{ hyperkitty_api_key }}
|
||||
networks:
|
||||
mailman:
|
||||
ipv4_address: 172.19.199.2
|
||||
|
||||
mailman-web:
|
||||
image: maxking/mailman-web:0.2
|
||||
container_name: mailman-web
|
||||
hostname: mailman-web
|
||||
depends_on:
|
||||
- database
|
||||
links:
|
||||
- mailman-core:mailman-core
|
||||
- database:database
|
||||
volumes:
|
||||
- /opt/mailman/web:/opt/mailman-web-data
|
||||
environment:
|
||||
- DATABASE_TYPE=postgres
|
||||
- DATABASE_URL=postgres://mailman:{{ postgresql}}@database/mailmandb
|
||||
- HYPERKITTY_API_KEY={{ hyperkitty_api_key }}
|
||||
networks:
|
||||
mailman:
|
||||
ipv4_address: 172.19.199.3
|
||||
|
||||
database:
|
||||
environment:
|
||||
POSTGRES_DB: mailmandb
|
||||
POSTGRES_USER: mailman
|
||||
POSTGRES_PASSWORD: mailmanpass
|
||||
restart: always
|
||||
image: postgres:9.6-alpine
|
||||
volumes:
|
||||
- /opt/mailman/database:/var/lib/postgresql/data
|
||||
networks:
|
||||
mailman:
|
||||
ipv4_address: 172.19.199.4
|
||||
|
||||
networks:
|
||||
mailman:
|
||||
driver: bridge
|
||||
ipam:
|
||||
driver: default
|
||||
config:
|
||||
-
|
||||
subnet: 172.19.199.0/24
|
Loading…
Reference in a new issue