🔥A cross-language distributed transaction manager. Support xa, tcc, saga, transactional messages. 跨语言分布式事务管理器
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

15 lines
446 B

# syntax=docker/dockerfile:1
FROM --platform=$TARGETPLATFORM golang:1.16-alpine as builder
ARG TARGETARCH
ARG TARGETOS
WORKDIR /app/dtm
# RUN go env -w GOPROXY=https://mirrors.aliyun.com/goproxy/,direct
EXPOSE 8080
COPY . .
RUN CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH go build -ldflags="-s -w"
FROM --platform=$TARGETPLATFORM alpine
COPY --from=builder /app/dtm/dtm /app/dtm/
ENV IS_DOCKER=1
WORKDIR /app/dtm
ENTRYPOINT ["/app/dtm/dtm"]