fix: use Aliyun Alpine mirror in Dockerfiles
Alpine CDN (dl-cdn.alpinelinux.org) unreachable from DinD containers. Switch to mirrors.aliyun.com for apk package downloads. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
75f8dca36b
commit
9e25c799d5
@ -8,6 +8,7 @@ WORKDIR /app/auth-service
|
|||||||
RUN go build -o /auth-service ./cmd/
|
RUN go build -o /auth-service ./cmd/
|
||||||
|
|
||||||
FROM ${BASE_REGISTRY}/alpine:3.20
|
FROM ${BASE_REGISTRY}/alpine:3.20
|
||||||
|
RUN sed -i "s|dl-cdn.alpinelinux.org|mirrors.aliyun.com|g" /etc/apk/repositories
|
||||||
RUN apk add --no-cache wget
|
RUN apk add --no-cache wget
|
||||||
COPY --from=builder /auth-service /auth-service
|
COPY --from=builder /auth-service /auth-service
|
||||||
EXPOSE 8081
|
EXPOSE 8081
|
||||||
|
|||||||
@ -8,6 +8,7 @@ WORKDIR /app/gateway
|
|||||||
RUN go build -o /gateway ./cmd/
|
RUN go build -o /gateway ./cmd/
|
||||||
|
|
||||||
FROM ${BASE_REGISTRY}/alpine:3.20
|
FROM ${BASE_REGISTRY}/alpine:3.20
|
||||||
|
RUN sed -i "s|dl-cdn.alpinelinux.org|mirrors.aliyun.com|g" /etc/apk/repositories
|
||||||
RUN apk add --no-cache wget
|
RUN apk add --no-cache wget
|
||||||
COPY --from=builder /gateway /gateway
|
COPY --from=builder /gateway /gateway
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
|
|||||||
@ -8,6 +8,7 @@ WORKDIR /app/purchaser-service
|
|||||||
RUN go build -o /purchaser-service ./cmd/
|
RUN go build -o /purchaser-service ./cmd/
|
||||||
|
|
||||||
FROM ${BASE_REGISTRY}/alpine:3.20
|
FROM ${BASE_REGISTRY}/alpine:3.20
|
||||||
|
RUN sed -i "s|dl-cdn.alpinelinux.org|mirrors.aliyun.com|g" /etc/apk/repositories
|
||||||
RUN apk add --no-cache wget
|
RUN apk add --no-cache wget
|
||||||
COPY --from=builder /purchaser-service /purchaser-service
|
COPY --from=builder /purchaser-service /purchaser-service
|
||||||
EXPOSE 8082
|
EXPOSE 8082
|
||||||
|
|||||||
@ -8,6 +8,7 @@ WORKDIR /app/textile-service
|
|||||||
RUN go build -o /textile-service ./cmd/
|
RUN go build -o /textile-service ./cmd/
|
||||||
|
|
||||||
FROM ${BASE_REGISTRY}/alpine:3.20
|
FROM ${BASE_REGISTRY}/alpine:3.20
|
||||||
|
RUN sed -i "s|dl-cdn.alpinelinux.org|mirrors.aliyun.com|g" /etc/apk/repositories
|
||||||
RUN apk add --no-cache wget
|
RUN apk add --no-cache wget
|
||||||
COPY --from=builder /textile-service /textile-service
|
COPY --from=builder /textile-service /textile-service
|
||||||
EXPOSE 8083
|
EXPOSE 8083
|
||||||
|
|||||||
@ -8,6 +8,7 @@ WORKDIR /app/washing-service
|
|||||||
RUN go build -o /washing-service ./cmd/
|
RUN go build -o /washing-service ./cmd/
|
||||||
|
|
||||||
FROM ${BASE_REGISTRY}/alpine:3.20
|
FROM ${BASE_REGISTRY}/alpine:3.20
|
||||||
|
RUN sed -i "s|dl-cdn.alpinelinux.org|mirrors.aliyun.com|g" /etc/apk/repositories
|
||||||
RUN apk add --no-cache wget
|
RUN apk add --no-cache wget
|
||||||
COPY --from=builder /washing-service /washing-service
|
COPY --from=builder /washing-service /washing-service
|
||||||
EXPOSE 8084
|
EXPOSE 8084
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user