From c2eb020d5c78185b86707dc176bfde31d7cdfe39 Mon Sep 17 00:00:00 2001 From: admin Date: Fri, 6 Feb 2026 19:15:55 +0700 Subject: [PATCH] Bug fixes pipeline --- Dockerfile | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 63fd720..2e861ba 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,14 +12,19 @@ RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o nats-ui main.go # Runtime stage FROM alpine:3.19 -RUN apk --no-cache add ca-certificates tzdata +RUN apk --no-cache add ca-certificates tzdata && \ + adduser -D -u 1000 -h /app appuser WORKDIR /app COPY --from=builder /app/nats-ui . -COPY ./index.html ./config.yaml ./ +COPY index.html config.yaml ./ + +RUN chmod +x nats-ui && chown -R appuser:appuser /app EXPOSE 8080 +USER appuser + ENTRYPOINT ["./nats-ui"] CMD ["config.yaml"]