Skip to content

Commit afbae9b

Browse files
committed
fixes
1 parent 61c19f4 commit afbae9b

File tree

4 files changed

+11
-16
lines changed

4 files changed

+11
-16
lines changed

packages/postgres-database/docker/Dockerfile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# syntax=docker/dockerfile:1
2-
FROM python:3.6-slim AS base
2+
ARG PYTHON_VERSION="3.11.9"
3+
ARG UV_VERSION="0.4"
4+
FROM ghcr.io/astral-sh/uv:${UV_VERSION} AS uv_build
5+
# we docker image is built based on debian
6+
FROM python:${PYTHON_VERSION}-slim-bookworm AS base
37

48
LABEL maintainer=sanderegg
59

@@ -30,7 +34,6 @@ RUN uv venv "${VIRTUAL_ENV}"
3034

3135
RUN --mount=type=cache,target=/root/.cache/uv \
3236
uv pip install --upgrade \
33-
pip~=24.0 \
3437
wheel \
3538
setuptools
3639

packages/service-integration/Dockerfile

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,13 @@ ENV LANG=C.UTF-8
4343
# Turns off writing .pyc files; superfluous on an ephemeral container.
4444
ENV PYTHONDONTWRITEBYTECODE=1 \
4545
VIRTUAL_ENV=/home/scu/.venv
46+
# https://docs.astral.sh/uv/guides/integration/docker/#compiling-bytecode
47+
ENV UV_COMPILE_BYTECODE=1
4648

4749
# Ensures that the python and pip executables used
4850
# in the image will be those from our virtualenv.
4951
ENV PATH="${VIRTUAL_ENV}/bin:$PATH"
5052

51-
5253
# -------------------------- Build stage -------------------
5354

5455
FROM base AS build
@@ -90,10 +91,6 @@ FROM base AS development
9091
# NOTE: this is necessary to allow to build development images but is the same as production here
9192
FROM base AS production
9293

93-
ENV PYTHONOPTIMIZE=TRUE
94-
# https://docs.astral.sh/uv/guides/integration/docker/#compiling-bytecode
95-
ENV UV_COMPILE_BYTECODE=1
96-
9794
WORKDIR /home/scu
9895
# ensure home folder is read/writable for user scu
9996
RUN chown -R scu /home/scu
@@ -102,7 +99,5 @@ USER scu
10299

103100
COPY --from=build --chown=scu:scu ${VIRTUAL_ENV} ${VIRTUAL_ENV}
104101

105-
# NOTE: do not activate ENV PYTHONOPTIMIZE=TRUE
106-
# https://docs.astral.sh/uv/guides/integration/docker/#compiling-bytecode
107-
ENV UV_COMPILE_BYTECODE=1 since excutable contains pytest code
102+
# NOTE: do not activate ENV PYTHONOPTIMIZE=TRUE since excutable contains pytest code
108103
ENTRYPOINT [ "ooil" ]

requirements/tools/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
#
1010
#
1111
ARG PYTHON_VERSION="3.11.9"
12+
ARG UV_VERSION="0.4"
13+
FROM ghcr.io/astral-sh/uv:${UV_VERSION} AS uv_build
14+
# we docker image is built based on debian
1215
FROM python:${PYTHON_VERSION}-slim-bookworm AS base
1316

1417
ENV VIRTUAL_ENV=/home/scu/.venv
@@ -39,7 +42,6 @@ RUN --mount=type=cache,target=/root/.cache/uv \
3942
# devenv
4043
RUN --mount=type=cache,target=/root/.cache/uv \
4144
uv pip install \
42-
pip-tools \
4345
pipreqs \
4446
pipdeptree && \
4547
uv pip list -vv

scripts/apt-packages-versions/Dockerfile

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
# syntax=docker/dockerfile:1
2-
3-
# Define arguments in the global scope
42
ARG PYTHON_VERSION="3.11.9"
5-
ARG UV_VERSION="0.4"
6-
FROM ghcr.io/astral-sh/uv:${UV_VERSION} AS uv_build
7-
# we docker image is built based on debian
83
FROM python:${PYTHON_VERSION}-slim-bookworm AS base
94

105
RUN \

0 commit comments

Comments
 (0)