8000 Update compose args presets handling by matiboux · Pull Request #103 · matiboux/dockerc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Update compose args presets handling #103

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 16 commits into from
Feb 4, 2025
Merged
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
34 changes: 17 additions & 17 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,23 +49,11 @@ WORKDIR /app


# --
# Runtime base image
# Test base image

FROM app_base AS app_runtime_base
FROM app_base AS app_test_base

# Set runtime environment
ENV APP_ENV=dev
ENV NODE_ENV=development

# Copy application source code
COPY --link . .


# --
# Test image

FROM app_runtime_base AS app_test

ENV APP_ENV=test
ENV PYTHONPATH=/app

Expand All @@ -82,24 +70,36 @@ RUN --mount=type=cache,target=/root/.cache/pip \
'pytest-cov ~= 5.0.0' \
'pytest-shell-utilities ~= 1.9.0'

COPY --link --chmod=755 ./docker/test-command.sh /usr/local/bin/app-test-command

# --
# Test base image

FROM app_test_base AS app_test

# Copy application source code
COPY --link . .

COPY --link --chmod=755 ./docker/test-command.sh /usr/local/bin/app-test-command
CMD [ "app-test-command" ]


# --
# Test watch image

FROM app_test AS app_test_watch
FROM app_test_base AS app_test_watch

# Install pytest-watch
# Install pytest-watch & pytest-testmon
RUN --mount=type=cache,target=/tmp/pip-cache \
export PIP_CACHE_DIR=/tmp/pip-cache && \
pip install \
'pytest-watch ~= 4.2.0' \
'pytest-testmon ~= 2.1.1'

# Configure pytest-testmon
ENV TESTMON_DATAFILE='/tmp/pytest/.testmondata'

# Copy application source code
COPY --link . .

COPY --link --chmod=755 ./docker/test-watch-command.sh /usr/local/bin/app-test-watch-command
CMD [ "app-test-watch-command" ]
Loading
0