Skip to content

Commit 71ef4e8

Browse files
committed
Updated docker file
1 parent 6c7433f commit 71ef4e8

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

infra/sidecar.Dockerfile

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,28 +19,23 @@ RUN export GITHUB_SHA="${COMMIT_SHA}" && bash -c '\
1919
else echo "building in standard mode"; make clean splitd splitd.yaml.tpl EXTRA_BUILD_ARGS="${EXTRA_BUILD_ARGS}"; \
2020
fi'
2121

22-
# Build yq from source with updated dependencies to avoid vulnerabilities
23-
ARG YQ_VERSION=v4.52.4
24-
WORKDIR /tmp/yq-build
25-
RUN git clone --depth 1 --branch ${YQ_VERSION} https://github.com/mikefarah/yq.git . && \
26-
go get golang.org/x/net@v0.51.0 && \
27-
go mod tidy && \
28-
go build -o /go/bin/yq . && \
29-
cd /splitd && rm -rf /tmp/yq-build
30-
3122
# ----- Runner image
3223
FROM debian:bookworm-slim AS runner
3324

25+
ARG YQ_VERSION=v4.52.4
26+
3427
RUN DEBIAN_FRONTEND=noninteractive \
3528
apt-get update && \
3629
apt-get install --no-install-recommends -y \
37-
bash ca-certificates socat && \
30+
bash ca-certificates wget socat && \
31+
wget -O /usr/local/bin/yq \
32+
"https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/yq_linux_amd64" && \
33+
chmod +x /usr/local/bin/yq && \
3834
mkdir -p /opt/splitd && \
3935
rm -rf /var/lib/apt/lists/*
4036

4137
COPY --from=builder /splitd/splitd /opt/splitd
4238
COPY --from=builder /splitd/splitd.yaml.tpl /opt/splitd
43-
COPY --from=builder /go/bin/yq /usr/local/bin/yq
4439
COPY infra/entrypoint.sh /opt/splitd
4540
RUN chmod +x /opt/splitd/entrypoint.sh
4641

0 commit comments

Comments
 (0)