Skip to content

Commit af45552

Browse files
aledbfroboquat
authored andcommitted
[ws-daemon] Check runc download is a binary
1 parent 6faf8a9 commit af45552

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

components/ws-daemon/debug.Dockerfile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,15 @@ RUN go get -u github.com/go-delve/delve/cmd/dlv
88

99
FROM alpine:3.16 as dl
1010
WORKDIR /dl
11-
RUN apk add --no-cache curl \
12-
&& curl -OL https://github.com/opencontainers/runc/releases/download/v1.1.3/runc.amd64 \
13-
&& chmod +x runc.amd64
11+
RUN apk add --no-cache curl file \
12+
&& curl -OsSL https://github.com/opencontainers/runc/releases/download/v1.1.4/runc.amd64 \
13+
&& chmod +x runc.amd64 \
14+
&& if ! file runc.amd64 | grep -iq "ELF 64-bit LSB executable"; then echo "runc.amd64 is not a binary file"; exit 1;fi
1415

1516
FROM ubuntu:22.04
1617

1718
## Installing coreutils is super important here as otherwise the loopback device creation fails!
18-
ARG CLOUD_SDK_VERSION=390.0.0
19+
ARG CLOUD_SDK_VERSION=402.0.0
1920
ENV CLOUD_SDK_VERSION=$CLOUD_SDK_VERSION
2021
ENV CLOUDSDK_CORE_DISABLE_PROMPTS=1
2122

components/ws-daemon/leeway.Dockerfile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@
44

55
FROM alpine:3.16 as dl
66
WORKDIR /dl
7-
RUN apk add --no-cache curl \
8-
&& curl -OL https://github.com/opencontainers/runc/releases/download/v1.1.3/runc.amd64 \
9-
&& chmod +x runc.amd64
7+
RUN apk add --no-cache curl file \
8+
&& curl -OsSL https://github.com/opencontainers/runc/releases/download/v1.1.4/runc.amd64 \
9+
&& chmod +x runc.amd64 \
10+
&& if ! file runc.amd64 | grep -iq "ELF 64-bit LSB executable"; then echo "runc.amd64 is not a binary file"; exit 1;fi
1011

1112
FROM ubuntu:22.04
1213

1314
## Installing coreutils is super important here as otherwise the loopback device creation fails!
14-
ARG CLOUD_SDK_VERSION=390.0.0
15+
ARG CLOUD_SDK_VERSION=402.0.0
1516
ENV CLOUD_SDK_VERSION=$CLOUD_SDK_VERSION
1617
ENV CLOUDSDK_CORE_DISABLE_PROMPTS=1
1718

0 commit comments

Comments
 (0)