Skip to content

Instantly share code, notes, and snippets.

@Yexiaoxing
Created January 4, 2018 18:01
Show Gist options
  • Save Yexiaoxing/833bfcc5d3e4e0c06a8b7f0bac7c4c57 to your computer and use it in GitHub Desktop.
Save Yexiaoxing/833bfcc5d3e4e0c06a8b7f0bac7c4c57 to your computer and use it in GitHub Desktop.
Docker Compose for Mailman 3
version: '2'
services:
mailman-core:
image: maxking/mailman-core:0.1
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=62eac924-6249-4c03-af04-e3e63b8340af
networks:
mailman:
ipv4_address: 172.19.199.2
mailman-web:
image: maxking/mailman-web:0.1
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:mailmanpass@database/mailmandb
- HYPERKITTY_API_KEY=62eac924-6249-4c03-af04-e3e63b8340af
- SECRET_KEY=0a04a8cd-b4cd-44a6-9862-562bc14c4cb9
- SERVE_FROM_DOMAIN=lists-docker.xiaoxing.us
- MAILMAN_ADMIN_USER=lists
- [email protected]
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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment