Skip to content

Commit eefc548

Browse files
committed
Pin apk versions
1 parent 14915ca commit eefc548

File tree

2 files changed

+26
-14
lines changed

2 files changed

+26
-14
lines changed

openid-connect-provider-debugger/Dockerfile

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,25 @@ FROM openresty/openresty:1.27.1.1-alpine-fat@sha256:aa8ea52fa35a296558aed8b392fb
33

44
ARG LUA_RESTY_OPENIDC_VERSION="1.7.6"
55

6-
HEALTHCHECK CMD ["/usr/bin/curl", "-i", "-s", "-S", "-f", "http://localhost"]
6+
SHELL ["/bin/bash", "-euo", "pipefail", "-c"]
77

8-
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
8+
HEALTHCHECK CMD ["/usr/bin/curl", "-i", "-s", "-S", "-f", "http://localhost"]
99

1010
COPY nginx.conf.patch /usr/local/openresty/nginx/conf/
1111

12-
# hadolint ignore=DL3018,DL4006
13-
RUN apk update \
14-
&& apk --no-cache add curl patch \
15-
&& rm -rf /var/cache/apk/* \
16-
&& /usr/local/openresty/luajit/bin/luarocks install lua-resty-openidc --pin "${LUA_RESTY_OPENIDC_VERSION}" \
17-
&& patch /usr/local/openresty/nginx/conf/nginx.conf /usr/local/openresty/nginx/conf/nginx.conf.patch \
18-
&& rm -f /usr/local/openresty/nginx/conf/nginx.conf.patch
12+
# hadolint ignore=DL4006
13+
RUN apk -U upgrade \
14+
&& apk add \
15+
curl=8.12.1-r0 \
16+
patch=2.7.6-r10 \
17+
&& if [[ $(apk -u list) ]] ; then \
18+
apk -u list ; \
19+
exit 1 ; \
20+
fi \
21+
&& rm -rf /var/cache/apk/* \
22+
&& /usr/local/openresty/luajit/bin/luarocks install lua-resty-openidc --pin "${LUA_RESTY_OPENIDC_VERSION}" \
23+
&& patch /usr/local/openresty/nginx/conf/nginx.conf /usr/local/openresty/nginx/conf/nginx.conf.patch \
24+
&& rm -f /usr/local/openresty/nginx/conf/nginx.conf.patch
1925

2026
COPY default.conf /etc/nginx/conf.d/
2127

openid-connect-provider-debugger/Dockerfile-test

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,16 @@ ARG USER_HOME=/home/default
99
ARG USER_ID=1000
1010
ARG USER_GECOS=Default
1111

12-
# hadolint ignore=DL3018
13-
RUN apk update \
14-
&& apk --no-cache add curl \
15-
&& rm -rf /var/cache/apk/*
12+
SHELL ["/bin/bash", "-euo", "pipefail", "-c"]
13+
14+
RUN apk -U upgrade \
15+
&& apk add \
16+
curl==8.12.1-r0 \
17+
&& if [[ $(apk -u list) ]] ; then \
18+
apk -u list ; \
19+
exit 1 ; \
20+
fi \
21+
&& rm -rf /var/cache/apk/*
1622

1723
RUN adduser \
1824
--home "${USER_HOME}" \
@@ -28,4 +34,4 @@ USER "${USER_NAME}"
2834
WORKDIR "${HOME}"
2935

3036
# sleep 60s to make sure that container survived its own healthcheck
31-
CMD ["/bin/sh", "-c", "/bin/sleep 60 ; /usr/bin/curl -i -s -S -f http://openid-connect-provider-debugger"]
37+
CMD ["/bin/bash", "-euo", "pipefail", "-c", "/bin/sleep 60 ; /usr/bin/curl -i -s -S -f http://openid-connect-provider-debugger"]

0 commit comments

Comments
 (0)