fix(docker): keep /sbin in PATH so apk works during image build
Build and Deploy / build-and-push (push) Successful in 59s
Build and Deploy / build-and-push (push) Successful in 59s
This commit is contained in:
@@ -19,11 +19,12 @@ RUN CGO_ENABLED=0 GOOS=linux go build -o /taskpool .
|
|||||||
# Production stage
|
# Production stage
|
||||||
FROM alpine:3.19
|
FROM alpine:3.19
|
||||||
|
|
||||||
|
# 注意:PATH 必须保留 /sbin:/usr/sbin,否则 alpine 的 apk 找不到
|
||||||
ENV TZ=Asia/Shanghai \
|
ENV TZ=Asia/Shanghai \
|
||||||
MISE_DATA_DIR=/app/envs/mise \
|
MISE_DATA_DIR=/app/envs/mise \
|
||||||
MISE_CONFIG_DIR=/app/envs/mise \
|
MISE_CONFIG_DIR=/app/envs/mise \
|
||||||
MISE_HIDE_UPDATE_WARNING=1 \
|
MISE_HIDE_UPDATE_WARNING=1 \
|
||||||
PATH="/app/envs/mise/shims:/app/envs/mise/bin:/usr/local/bin:/usr/bin:/bin"
|
PATH="/app/envs/mise/shims:/app/envs/mise/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
|
||||||
|
|
||||||
RUN apk add --no-cache \
|
RUN apk add --no-cache \
|
||||||
nginx supervisor bash curl wget ca-certificates tzdata git rsync openssh-client \
|
nginx supervisor bash curl wget ca-certificates tzdata git rsync openssh-client \
|
||||||
|
|||||||
Reference in New Issue
Block a user