Squash
All checks were successful
🏗️✨ Build Workflow / 🖥️ 🔨 Build (push) Successful in 20m10s

This commit is contained in:
2025-08-25 21:23:08 -04:00
parent 8f813e1a6e
commit db068f5c6a
5 changed files with 11 additions and 50 deletions

View File

@@ -5,21 +5,18 @@ WORKDIR /app
ADD . .
ENV GOPRIVATE=git.siteworxpro.com
ENV CGO_ENABLED=0
RUN go mod download && go build -o aws-iam-anywhere-refresher .
RUN go mod tidy && go build -o aws-iam-anywhere-refresher .
FROM siteworxpro/alpine:3.21.4 AS runtime
RUN apt update && apt install -yq ca-certificates curl
RUN curl -Ls https://siteworxpro.com/hosted/Siteworx+Root+CA.pem -o /usr/local/share/ca-certificates/sw.crt \
&& update-ca-certificates
WORKDIR /app
COPY --from=build /app/aws-iam-anywhere-refresher /app/aws-iam-anywhere-refresher
RUN useradd -b /app iam && \
RUN apk add --no-cache gcompat
RUN adduser -Dh /app iam && \
chown iam:iam /app/aws-iam-anywhere-refresher
USER iam