diff --git a/.ci/40-delivery/app.Dockerfile b/.ci/40-delivery/Dockerfile similarity index 76% rename from .ci/40-delivery/app.Dockerfile rename to .ci/40-delivery/Dockerfile index 90578e9..b568446 100644 --- a/.ci/40-delivery/app.Dockerfile +++ b/.ci/40-delivery/Dockerfile @@ -15,18 +15,18 @@ RUN apt update && \ tee /etc/apt/sources.list.d/postgresql.list && \ apt update && \ apt install -y postgresql-client-15 && \ - groupadd --system -g 1001 themaker \ - && useradd --system --create-home -g 1001 --no-user-group -u 1001 themaker + groupadd --system -g 1001 themaker && \ + useradd --system --create-home -g 1001 --no-user-group -u 1001 themaker + WORKDIR /home/themaker COPY dist/database_sync*.whl ./ + RUN chown -R themaker:themaker /home/themaker -COPY ../../.venv .venv -RUN cp -r .venv/lib/*/site-packages/* /usr/local/lib/python3.10/site-packages && rm -rf .venv +RUN pip install --no-cache-dir database_sync*.whl && \ + pip install --no-cache-dir psycopg2 USER themaker -RUN pip install --no-index database_sync*.whl \ - && pip install --force-reinstall psycopg2 ENTRYPOINT ["python", "-m", "database_sync"] diff --git a/.github/workflows/default.yaml b/.github/workflows/default.yaml index f7d75eb..eba568c 100644 --- a/.github/workflows/default.yaml +++ b/.github/workflows/default.yaml @@ -15,6 +15,10 @@ on: # checks: 'write' # code_check-style_golangci_lint # contents: 'write' # delivery-release +permissions: + contents: read + packages: write + jobs: default: uses: 'rios0rios0/pipelines/.github/workflows/python-docker.yaml@main' diff --git a/CHANGELOG.md b/CHANGELOG.md index 169d2d4..649e256 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,7 @@ Exceptions are acceptable depending on the circumstances (critical bug fixes tha - fixed missing exclude table command for the id_seq of the table ignored - fixed dropping the id_seq table for the ignored table +- fixed `Dockerfile` and CI `workflow` to support Docker image delivery step ### Removed