change layout
CI / changes (push) Successful in 5s
CI / docker-bff (push) Failing after 7s
CI / docker-product (push) Failing after 5s
CI / docker-admin (push) Failing after 4s
CI / docker-user (push) Failing after 6s

This commit is contained in:
2026-08-20 15:41:44 +08:00
parent 57e04be304
commit be8f89f449
176 changed files with 7009 additions and 4498 deletions
+38
View File
@@ -0,0 +1,38 @@
# syntax=docker/dockerfile:1
FROM golang:1.26.5-alpine AS builder
WORKDIR /src
ENV GOPROXY=https://goproxy.cn,direct \
CGO_ENABLED=0 \
GOOS=linux \
GOARCH=amd64
COPY pkg ./pkg
COPY product/go.mod product/go.sum ./product/
WORKDIR /src/product
RUN --mount=type=cache,target=/go/pkg/mod \
go mod download
COPY product/ ./
RUN --mount=type=cache,target=/go/pkg/mod \
--mount=type=cache,target=/root/.cache/go-build \
go build -ldflags="-s -w" -o /out/product .
FROM alpine:3.22
WORKDIR /app
ENV TZ=Asia/Shanghai
RUN apk add --no-cache tzdata \
&& cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
&& echo "Asia/Shanghai" > /etc/timezone
COPY --from=builder /out/product .
EXPOSE 10100
CMD ["./product", "-f", "etc/product.yaml"]