Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 43 additions & 23 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@ name: build
on:
push:
branches:
- "release-4.5.X"
- "dev-4.5.X"
- "main"
- "master"
- "dev"
tags:
- "4.*.*"

- "*.*.*"
- "*.*.*.*.*"
pull_request:
branches:
- "release-4.5.X"
- "main"
- "master"
schedule:
- cron: "0 1 * * WED"

Expand All @@ -31,21 +33,30 @@ jobs:
- "17.0"
- "18.0"
- "19.0"
python_from:
- "python:3.12-slim-trixie"
python:
- "python:3.12"
flavor:
- main
- core
include:
- odoo_serie: "12.0"
python_from: "python:3.9-slim-trixie"
python: "python:3.9"
flavor: main
- odoo_serie: "13.0"
python_from: "python:3.9-slim-trixie"
python: "python:3.9"
flavor: main
- odoo_serie: "14.0"
python: "python:3.9"
flavor: main
- odoo_serie: "14.0"
python_from: "python:3.9-slim-trixie"
continue-on-error: ${{ matrix.odoo_serie == '12.0' }}
python: "python:3.9"
flavor: core
continue-on-error: ${{ matrix.odoo_serie == '12.0' || matrix.flavor == 'core' }}

steps:
- uses: actions/checkout@v6

- name: Set up Docker Buildx
- name: Setup Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v4
with:
Expand All @@ -57,34 +68,42 @@ jobs:
with:
images: ghcr.io/camptocamp/docker-odoo-project
flavor: |
prefix=${{ matrix.odoo_serie }}-,onlatest=true
prefix=${{ matrix.odoo_serie }}${{ matrix.flavor == 'core' && '-core-' || '-' }},onlatest=true
tags: |
type=raw,value={{branch}}-latest
type=raw,value={{branch}}-{{date 'YYYYMMDD'}}
type=ref,event=tag
type=ref,event=tag,priority=900,enable=${{ (matrix.flavor == 'main' && contains(github.ref, '/4.')) || (matrix.flavor == 'core' && contains(github.ref, '/5.')) }}
type=ref,event=pr
type=schedule,pattern={{branch}}-nightly
type=raw,value={{branch}}
type=schedule,priority=800
type=raw,priority=500,value=latest,enable={{is_default_branch}}
type=raw,priority=400,value={{date 'YYYYMMDD'}},enable={{is_default_branch}}
type=raw,priority=300,value={{branch}}-latest,enable={{is_not_default_branch}}
type=raw,priority=300,value={{branch}}-{{date 'YYYYMMDD'}},enable={{is_not_default_branch}}
type=raw,priority=200,value={{branch}},enable={{is_not_default_branch}}

- name: Setup build dir
id: setup
run: |
VERSION=${{ matrix.odoo_serie }} SRC=build make setup
echo "Dockerfile=./build/${{ matrix.flavor == 'core' && 'core.' || '' }}Dockerfile" >> $GITHUB_OUTPUT
echo "python-from=${{ matrix.python }}-slim-trixie" >> $GITHUB_OUTPUT
echo "image-tag=ci-${{ matrix.flavor == 'core' && '5' || '4' }}xx-latest:${{ matrix.odoo_serie }}" >> $GITHUB_OUTPUT

- name: Build
uses: docker/build-push-action@v7
with:
context: ./build
file: ${{ steps.setup.outputs.Dockerfile }}
build-args: |
VERSION=${{ matrix.odoo_serie }}
build-contexts: |
python=docker-image://${{ matrix.python_from }}
python=docker-image://${{ steps.setup.outputs.python-from }}
push: false
load: true
tags: ci-4xx-latest:${{ matrix.odoo_serie }}
tags: ${{ steps.setup.outputs.image-tag }}
labels: ${{ steps.docker_meta.outputs.labels }}

- name: Test
run: make VERSION=${{ matrix.odoo_serie }} test
run: |
make VERSION=${{ matrix.odoo_serie }} IMAGE_LATEST=${{ steps.setup.outputs.image-tag }} test

- name: Scan image
id: scan
Expand All @@ -93,7 +112,7 @@ jobs:
sysdig-secure-url: https://eu1.app.sysdig.com
stop-on-failed-policy-eval: false
stop-on-processing-error: false
image-tag: ci-4xx-latest:${{ matrix.odoo_serie }}
image-tag: ${{ steps.setup.outputs.image-tag }}
skip-upload: false
sysdig-secure-token: ${{ secrets.SYSDIG_SECURE_TOKEN }}

Expand All @@ -111,10 +130,11 @@ jobs:
uses: docker/build-push-action@v7
with:
context: ./build
file: ${{ steps.setup.outputs.Dockerfile }}
build-args: |
VERSION=${{ matrix.odoo_serie }}
build-contexts: |
python=docker-image://${{ matrix.python_from }}
python=docker-image://${{ steps.setup.outputs.python-from }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.docker_meta.outputs.tags }}
labels: ${{ steps.docker_meta.outputs.labels }}
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/hadolint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,10 @@ on:
- "main"
- "master"
- "dev"
- "release-4.5.X"
pull_request:
branches:
- "main"
- "master"
- "release-4.5.X"

jobs:

Expand Down
5 changes: 5 additions & 0 deletions 12.0/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ COPY ./templates /templates
COPY ./before-migrate-entrypoint.d /before-migrate-entrypoint.d
COPY ./start-entrypoint.d /start-entrypoint.d
COPY ./MANIFEST.in /odoo
COPY --chmod=644 ./env_odoo.sh /odoo-bin/
# Init PG variables during Shell initialization so it will be available
# when doing 'docker compose exec odoo gosu odoo bash'
RUN set -x; echo >> /etc/bash.bashrc \
"if [ -f /odoo-bin/env_postgres.sh ]; then . /odoo-bin/env_postgres.sh; fi"

ENV ODOO_VERSION=$VERSION \
PATH=/odoo-bin:$PATH \
Expand Down
5 changes: 5 additions & 0 deletions 13.0/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ COPY ./templates /templates
COPY ./before-migrate-entrypoint.d /before-migrate-entrypoint.d
COPY ./start-entrypoint.d /start-entrypoint.d
COPY ./MANIFEST.in /odoo
COPY --chmod=644 ./env_odoo.sh /odoo-bin/
# Init PG variables during Shell initialization so it will be available
# when doing 'docker compose exec odoo gosu odoo bash'
RUN set -x; echo >> /etc/bash.bashrc \
"if [ -f /odoo-bin/env_postgres.sh ]; then . /odoo-bin/env_postgres.sh; fi"

ENV ODOO_VERSION=$VERSION \
PATH=/odoo-bin:$PATH \
Expand Down
2 changes: 1 addition & 1 deletion 14.0/base_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,5 @@ pycodestyle==2.12.1
pyflakes==3.2.0
setuptools==79.0.1
unicodecsv==0.14.1
urllib3==2.6.3
urllib3==1.26.20
wrapt==1.16.0
42 changes: 42 additions & 0 deletions 14.0/extra_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Extra python dependencies
algoliasearch==4.1.1
Adyen==12.3.0
cachetools==5.5.0
cerberus==1.3.5
boto3==1.35.6
factur-x==3.1
invoice2data==0.4.5
mailjet-rest==1.3.4
openupgradelib==3.6.1
paramiko==3.4.1
parse-accept-language==0.1.2
paypalrestsdk==1.13.3
phonenumbers==8.13.44
pyOpenSSL==24.2.1
pyquerystring==1.1
pysimplesoap==1.16.2
requests-mock==1.12.1
slugify==0.0.1
stripe==10.8.0
unidecode==1.3.8
vcrpy==7.0.0

# Library dependency
aiohttp==3.13.3
asn1crypto==1.5.1
bcrypt==4.2.0
botocore==1.35.6
cffi==1.17.0
dateparser==1.2.0
jmespath==1.0.1
multidict==6.0.5
pdfminer.six==20251107
pyasn1==0.6.3
pycparser==2.22
pycryptodome==3.20.0
PyNaCl==1.5.0
pytesseract==0.3.13
regex==2024.7.24
s3transfer==0.10.2
tzlocal==5.2
yarl==1.22.0
2 changes: 1 addition & 1 deletion 14.0/templates/odoo.cfg.tmpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[options]
addons_path = {{ .Env.ADDONS_PATH }}
data_dir = /data/odoo
data_dir = {{ default .Env.DATA_DIR "/data/odoo" }}
auto_reload = False
db_host = {{ .Env.DB_HOST }}
db_name = {{ .Env.DB_NAME }}
Expand Down
39 changes: 39 additions & 0 deletions 15.0/extra_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Extra python dependencies
algoliasearch==4.1.1
Adyen==12.3.0
cachetools==5.5.0
cerberus==1.3.5
boto3==1.35.6
factur-x==3.1
invoice2data==0.4.5
mailjet-rest==1.3.4
openupgradelib==3.6.1
paramiko==3.4.1
parse-accept-language==0.1.2
paypalrestsdk==1.13.3
phonenumbers==8.13.44
pyquerystring==1.1
pysimplesoap==1.16.2
requests-mock==1.12.1
slugify==0.0.1
stripe==10.8.0
unidecode==1.3.8
vcrpy==7.0.0

# Library dependency
aiohttp==3.13.3
asn1crypto==1.5.1
bcrypt==4.2.0
botocore==1.35.6
dateparser==1.2.0
jmespath==1.0.1
multidict==6.0.5
pdfminer.six==20260107
pyasn1==0.6.3
pycryptodome==3.20.0
PyNaCl==1.5.0
pytesseract==0.3.13
regex==2024.7.24
s3transfer==0.10.2
tzlocal==5.2
yarl==1.22.0
2 changes: 1 addition & 1 deletion 15.0/templates/odoo.cfg.tmpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[options]
addons_path = {{ .Env.ADDONS_PATH }}
data_dir = /data/odoo
data_dir = {{ default .Env.DATA_DIR "/data/odoo" }}
auto_reload = False
db_host = {{ .Env.DB_HOST }}
db_name = {{ .Env.DB_NAME }}
Expand Down
39 changes: 39 additions & 0 deletions 16.0/extra_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Extra python dependencies
algoliasearch==4.1.1
Adyen==12.3.0
cachetools==5.5.0
cerberus==1.3.5
boto3==1.35.6
factur-x==3.1
invoice2data==0.4.5
mailjet-rest==1.3.4
openupgradelib==3.6.1
paramiko==3.4.1
parse-accept-language==0.1.2
paypalrestsdk==1.13.3
phonenumbers==8.13.44
pyquerystring==1.1
pysimplesoap==1.16.2
requests-mock==1.12.1
slugify==0.0.1
stripe==10.8.0
unidecode==1.3.8
vcrpy==7.0.0

# Library dependency
aiohttp==3.13.3
asn1crypto==1.5.1
bcrypt==4.2.0
botocore==1.35.6
dateparser==1.2.0
jmespath==1.0.1
multidict==6.0.5
pdfminer.six==20260107
pyasn1==0.6.3
pycryptodome==3.20.0
PyNaCl==1.5.0
pytesseract==0.3.13
regex==2024.7.24
s3transfer==0.10.2
tzlocal==5.2
yarl==1.22.0
2 changes: 1 addition & 1 deletion 16.0/templates/odoo.cfg.tmpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[options]
addons_path = {{ .Env.ADDONS_PATH }}
data_dir = /data/odoo
data_dir = {{ default .Env.DATA_DIR "/data/odoo" }}
auto_reload = False
db_host = {{ .Env.DB_HOST }}
db_name = {{ .Env.DB_NAME }}
Expand Down
39 changes: 39 additions & 0 deletions 17.0/extra_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Extra python dependencies
algoliasearch==4.1.1
Adyen==12.3.0
cachetools==5.5.0
cerberus==1.3.5
boto3==1.35.6
factur-x==3.1
invoice2data==0.4.5
mailjet-rest==1.3.4
openupgradelib==3.6.1
paramiko==3.4.1
parse-accept-language==0.1.2
paypalrestsdk==1.13.3
phonenumbers==8.13.44
pyquerystring==1.1
pysimplesoap==1.16.2
requests-mock==1.12.1
slugify==0.0.1
stripe==10.8.0
unidecode==1.3.8
vcrpy==7.0.0

# Library dependency
aiohttp==3.13.3
asn1crypto==1.5.1
bcrypt==4.2.0
botocore==1.35.6
dateparser==1.2.0
jmespath==1.0.1
multidict==6.0.5
pdfminer.six==20260107
pyasn1==0.6.3
pycryptodome==3.20.0
PyNaCl==1.5.0
pytesseract==0.3.13
regex==2024.7.24
s3transfer==0.10.2
tzlocal==5.2
yarl==1.22.0
2 changes: 1 addition & 1 deletion 17.0/templates/odoo.cfg.tmpl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[options]
addons_path = {{ .Env.ADDONS_PATH }}
data_dir = /data/odoo
data_dir = {{ default .Env.DATA_DIR "/data/odoo" }}
auto_reload = False
db_host = {{ .Env.DB_HOST }}
db_name = {{ .Env.DB_NAME }}
Expand Down
Loading
Loading