The base images does nothing alone, it only contains the dependencies and a few tools, but you need to create an inheriting image with the odoo and addons code.
Follow the steps:
-
Create directories. This is mandatory, they will be copied in the image
mkdir -p odoo/external-src odoo/local-src odoo/data odoo/songs -
Add a submodule for Odoo (official or OCA/OCB)
git submodule init git submodule add git@github.com:odoo/odoo.git odoo/src -
Optionally add submodules for external addons in
odoo/external-srcgit submodule add git@github.com:OCA/server-tools.git odoo/external-src/server-tools -
Optionally add custom addons in
odoo/local-src -
Create the Dockerfile, the bare minimum being (see also the example file that installs additional dependencies):
FROM camptocamp/odoo-project:11.0 MAINTAINER <name> ENV ADDONS_PATH=/odoo/local-src,/odoo/external-src/server-tools,/odoo/src/addons -
Build your image
docker build -t youruser/odoo-project-example . -
Optionally create a docker-compose.yml file. This example is a development composition.