Skip to content

Instantly share code, notes, and snippets.

@eneldoserrata
Forked from thomas15v/docker-compose.yml
Created April 7, 2019 04:43
Show Gist options
  • Save eneldoserrata/231f15bbd608672612713d16552f0562 to your computer and use it in GitHub Desktop.
Save eneldoserrata/231f15bbd608672612713d16552f0562 to your computer and use it in GitHub Desktop.
Install odoo with docker-compose
version: '2'
services:
db:
image: postgres:9.4
restart: always
environment:
- POSTGRES_USER=odoo
- POSTGRES_PASSWORD=odoo
odoo:
image: odoo:11
restart: always
links:
- db:db
volumes:
- ./odoo.conf:/etc/odoo/odoo.conf
- ./extra-addons:/mnt/extra-addons
labels:
- "traefik.enable=true"
- "traefik.odoo.frontend.rule=Host:example.com"
- "traefik.odoo.port=8069"
- "traefik.chat.frontend.rule=Host:example.com;PathPrefix:/longpolling"
- "traefik.chat.port=8072"
proxy:
image: traefik
command: --web -c /etc/traefik/traefik.toml --LOGLEVEL=debug
restart: always
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik.toml:/etc/traefik/traefik.toml
- /acme
[options]
addons_path = /mnt/extra-addons
data_dir = /var/lib/odoo
admin_passwd = a_random_password
workers = 2
InsecureSkipVerify = true
defaultEntryPoints = ["https", "http"]
[entryPoints]
[entryPoints.http]
address = ":80"
[entryPoints.http.redirect]
entryPoint = "https"
[entryPoints.https]
address = ":443"
compress = true
[entryPoints.https.tls]
[acme]
email = "[email protected]"
storage = "/acme/acme.json"
entryPoint = "https"
OnHostRule = true
[acme.httpChallenge]
entryPoint = "http"
[docker]
endpoint = "unix:///var/run/docker.sock"
domain = "docker.localhost"
exposedbydefault = false
watch = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment