Skip to content

Commit

Permalink
fix example
Browse files Browse the repository at this point in the history
  • Loading branch information
gurneyalex committed Jan 4, 2024
1 parent 667e832 commit ce0c9f8
Show file tree
Hide file tree
Showing 17 changed files with 13 additions and 15 deletions.
11 changes: 5 additions & 6 deletions example/odoo/Dockerfile → example/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ MAINTAINER Camptocamp
# time of the image on the server (layers are reused)
RUN mkdir -p /odoo/src/odoo
COPY ./src /odoo/src/odoo
COPY ./external-src /odoo/external-src
COPY ./local-src /odoo/local-src
COPY ./odoo/addons /odoo/odoo/addons
COPY ./data /odoo/data
COPY ./songs /odoo/songs
COPY ./setup.py /odoo/
Expand All @@ -26,11 +25,11 @@ RUN set -x; \

COPY ./requirements.txt /odoo/
USER odoo
RUN pip install -e /odoo
RUN pip install -e /odoo/src/odoo
RUN cd /odoo && pip install --user -r requirements.txt
RUN pip install --user -e /odoo/src/odoo
RUN pip install --user -e /odoo

# Project's specifics packages
RUN cd /odoo && pip install -r requirements.txt

ENV ADDONS_PATH=/odoo/local-src,/odoo/src/odoo/addons
ENV ADDONS_PATH=/odoo/odoo/addons,/odoo/src/odoo/addons

Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ RUN set -x; \
COPY ./requirements.txt /odoo/
RUN cd /odoo && pip install -r requirements.txt

ENV ADDONS_PATH=/odoo/local-src,/odoo/src/addons
ENV ADDONS_PATH=/odoo/odoo/addons,/odoo/src/addons
6 changes: 3 additions & 3 deletions example/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@ Follow the steps:

1. Create directories. This is mandatory, they will be copied in the image

mkdir -p odoo/external-src odoo/local-src odoo/data odoo/songs
mkdir -p odoo/addons data songs

2. Add a submodule for Odoo (official or OCA/OCB)

git submodule init
git submodule add [email protected]:odoo/odoo.git odoo/src

3. Optionally add submodules for external addons in `odoo/external-src`

git submodule add [email protected]:OCA/server-tools.git odoo/external-src/server-tools

4. Optionally add custom addons in `odoo/local-src`
4. Optionally add custom addons in `odoo/addons`

6. Create the Dockerfile, the bare minimum being (see also [the example
file](odoo/Dockerfile) that installs additional dependencies):
Expand Down
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion example/odoo/external-src/README.md

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions example/test-compose.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
# Composition used to run automated tests on the images
# Used by the Makefile at the repository's root

version: '2'
version: '3.8'

services:
odoo:
build: ./odoo/
build: .
depends_on:
- db
- kwkhtmltopdf
volumes:
- "data-odoo:/data/odoo"
- "./odoo/src/odoo:/odoo/src/odoo/odoo"
- "./odoo/src/addons:/odoo/src/odoo/addons"
- "./odoo/src/odoo:/odoo/src/odoo"
- "./odoo/addons:/odoo/odoo/addons"
environment:
- DB_USER=odoo
- DB_PASS=odoo
Expand Down

0 comments on commit ce0c9f8

Please sign in to comment.