Last active
August 25, 2022 13:19
-
-
Save KhanhhNe/2b94475c902ff63a95f42cbf0a59527b to your computer and use it in GitHub Desktop.
Docker compose, Odoo config file and install script (for VPS installation) for Odoo addons development purpose.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[options] | |
addons_path = /mnt/extra-addons | |
db_name = odoo15 | |
admin_email = admin | |
admin_passwd = admin | |
dev = all | |
log_level = debug |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.1' | |
services: | |
web: | |
image: odoo:latest | |
depends_on: | |
- db | |
ports: | |
- "8069:8069" | |
volumes: | |
- odoo-web-data:/var/lib/odoo | |
- ./.odoorc:/etc/odoo/odoo.conf | |
- ./custom_addons:/mnt/extra-addons | |
db: | |
image: postgres:latest | |
environment: | |
- POSTGRES_DB=postgres | |
- POSTGRES_USER=odoo | |
- POSTGRES_PASSWORD=odoo | |
- PGDATA=/var/lib/postgresql/data | |
volumes: | |
- odoo-db-data:/var/lib/postgresql/data | |
volumes: | |
odoo-web-data: | |
odoo-db-data: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pre-install | |
sudo apt install postgresql -y | |
# wkhtmlox | |
wget -O wkhtmltox.deb https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.5/wkhtmltox_0.12.5-1.focal_amd64.deb | |
sudo dpkg -i wkhtmltox.deb | |
sudo apt-get -y install | |
sudo dpkg -i wkhtmltox.deb | |
# Odoo | |
wget -O - https://nightly.odoo.com/odoo.key | sudo apt-key add - | |
touch /etc/apt/sources.list.d/odoo.list | |
printf "deb http://nightly.odoo.com/15.0/nightly/deb/ ./" | sudo tee /etc/apt/sources.list.d/odoo.list > /dev/null | |
sudo apt-get update | |
sudo apt-get -y install odoo | |
# Retry if needed | |
sudo apt-get -y --fix-broken install | |
sudo apt-get -y install odoo | |
# Addons | |
sudo mkdir /opt/odoo-custom-addons | |
printf "[options]\ndev=all\naddons_path = /opt/odoo-custom-addons" | sudo tee /etc/odoo/odoo.conf > /dev/null | |
sudo systemctl restart odoo.service |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment