fix: docker cache permission issue (#57)

This commit is contained in:
安和
2025-05-08 18:38:28 +08:00
committed by GitHub
parent 5f78db90c7
commit d2ddb9193a

View File

@@ -11,8 +11,17 @@ RUN CGO_ENABLED=0 GOOS=linux go build -o saveany-bot .
FROM alpine:latest
RUN addgroup -S saveany && adduser -S saveany -G saveany
WORKDIR /app
RUN mkdir -p /app/data /app/downloads /app/cache && \
chown -R saveany:saveany /app
COPY --from=builder /app/saveany-bot .
CMD ["./saveany-bot"]
RUN chmod +x /app/saveany-bot
USER saveany
CMD ["./saveany-bot"]