fix: make non-root user work
All checks were successful
ZeroDownTime/aws-iam-authenticator/pipeline/head This commit looks good
ZeroDownTime/aws-iam-authenticator/pipeline/tag This commit looks good

This commit is contained in:
Stefan Reimer 2025-01-17 12:00:18 +00:00
parent b66616d5b8
commit 375bf99504

View File

@ -5,7 +5,6 @@ FROM alpine:${DISTRO_VERSION}
ARG DISTRO_VERSION ARG DISTRO_VERSION
ARG VERSION ARG VERSION
RUN adduser -D -u 10000 aws-iam-authenticator
RUN apk add --update ca-certificates RUN apk add --update ca-certificates
RUN echo "@kubezero https://cdn.zero-downtime.net/alpine/v${DISTRO_VERSION}/kubezero" >> "/etc/apk/repositories" RUN echo "@kubezero https://cdn.zero-downtime.net/alpine/v${DISTRO_VERSION}/kubezero" >> "/etc/apk/repositories"
@ -21,5 +20,5 @@ COPY --from=0 /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=0 /lib/ld-musl-*.so.1 /lib/ COPY --from=0 /lib/ld-musl-*.so.1 /lib/
COPY --from=0 /usr/bin/aws-iam-authenticator /aws-iam-authenticator COPY --from=0 /usr/bin/aws-iam-authenticator /aws-iam-authenticator
USER aws-iam-authenticator USER 65534
ENTRYPOINT ["/aws-iam-authenticator"] ENTRYPOINT ["/aws-iam-authenticator"]