Skip to content
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

Using UBI work image for smaller container size #458

Closed
wants to merge 1 commit into from
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
9 changes: 4 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Generate a container that generates requirements.txt
ARG PY_VERSION=3.7
ARG PY_VERSION=3.9
FROM python:${PY_VERSION} as source

ARG DEV
Expand All @@ -14,14 +14,13 @@ COPY Pipfile ./Pipfile
# Generate requirements.txt file from Pipfile
RUN if [ -z ${DEV} ]; \
then \
pipenv lock -r > requirements.txt; \
pipenv lock > requirements.txt; \
else \
pipenv lock --dev -r > requirements.txt; \
pipenv lock --dev > requirements.txt; \
fi

# Generate work image
ARG PY_VERSION
FROM python:${PY_VERSION}
FROM registry.access.redhat.com/ubi9/python-39

# Project maintainer
LABEL maintainer="frolland@redhat.com"
Expand Down
2 changes: 1 addition & 1 deletion Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ idna = ">=2.5,<3"

[requires]

python_version = "3.7"
python_version = "3.9"