chore(docker): 确保二进制文件具有执行权限

- 在 Dockerfile 中添加 chmod 命令,确保构建的二进制文件具有执行权限,以避免运行时错误。
This commit is contained in:
zhouyonggao 2025-12-20 15:21:53 +08:00
parent 7b6c4f2cf2
commit 9bc99c19ed
1 changed files with 2 additions and 0 deletions

View File

@ -68,6 +68,8 @@ RUN apk add --no-cache ca-certificates tzdata && \
rm -rf /var/cache/apk/*
WORKDIR /app
COPY --from=builder /out/server /app/server
# 确保二进制文件有执行权限
RUN chmod +x /app/server
EXPOSE 8077
USER appuser:appuser
ENTRYPOINT ["/app/server"]