File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -5,12 +5,15 @@ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:${PYTHON_VERSION}-alpine A
55COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
66RUN chmod +x /usr/bin/fwatchdog
77
8+ ARG UPGRADE_PACKAGES=false
9+
810ARG ADDITIONAL_PACKAGE
911# Alternatively use ADD https:// (which will not be cached by Docker builder)
1012
11- RUN apk --no-cache add openssl-dev ${ADDITIONAL_PACKAGE}
13+ RUN if [ "${UPGRADE_PACKAGES}" = "true" ] || [ "${UPGRADE_PACKAGES}" = "1" ]; then apk --no-cache upgrade; fi && \
14+ apk --no-cache add openssl-dev ${ADDITIONAL_PACKAGE}
1215
13- # Add non root user
16+ # Add non root user
1417RUN addgroup -S app && adduser app -S -G app
1518RUN chown app /home/app
1619
Original file line number Diff line number Diff line change @@ -5,10 +5,12 @@ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:${PYTHON_VERSION}-alpine A
55COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
66RUN chmod +x /usr/bin/fwatchdog
77
8+ ARG UPGRADE_PACKAGES
89ARG ADDITIONAL_PACKAGE
910# Alternatively use ADD https:// (which will not be cached by Docker builder)
1011
11- RUN apk --no-cache add ${ADDITIONAL_PACKAGE}
12+ RUN if [ "${UPGRADE_PACKAGES}" = "true" ] || [ "${UPGRADE_PACKAGES}" = "1" ]; then apk --no-cache upgrade; fi && \
13+ apk --no-cache add ${ADDITIONAL_PACKAGE}
1214
1315# Add non root user
1416RUN addgroup -S app && adduser app -S -G app
You can’t perform that action at this time.
0 commit comments