File tree 2 files changed +8
-3
lines changed
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
5
5
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
6
6
RUN chmod +x /usr/bin/fwatchdog
7
7
8
+ ARG UPGRADE_PACKAGES=false
9
+
8
10
ARG ADDITIONAL_PACKAGE
9
11
# Alternatively use ADD https:// (which will not be cached by Docker builder)
10
12
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}
12
15
13
- # Add non root user
16
+ # Add non root user
14
17
RUN addgroup -S app && adduser app -S -G app
15
18
RUN chown app /home/app
16
19
Original file line number Diff line number Diff line change @@ -5,10 +5,12 @@ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:${PYTHON_VERSION}-alpine A
5
5
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
6
6
RUN chmod +x /usr/bin/fwatchdog
7
7
8
+ ARG UPGRADE_PACKAGES
8
9
ARG ADDITIONAL_PACKAGE
9
10
# Alternatively use ADD https:// (which will not be cached by Docker builder)
10
11
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}
12
14
13
15
# Add non root user
14
16
RUN addgroup -S app && adduser app -S -G app
You can’t perform that action at this time.
0 commit comments