github.com/matrixorigin/matrixone@v1.2.0/optools/images/Dockerfile (about)

     1  FROM golang:1.21.5-bookworm as builder
     2  
     3  # goproxy
     4  ARG GOPROXY="https://proxy.golang.org,direct"
     5  RUN go env -w GOPROXY=${GOPROXY}
     6  
     7  RUN mkdir -p /go/src/github.com/matrixorigin/matrixone
     8  
     9  WORKDIR /go/src/github.com/matrixorigin/matrixone
    10  
    11  COPY go.mod go.mod
    12  COPY go.sum go.sum
    13  
    14  # cache deps before building and copying source so that we don't need to re-download as much
    15  # and so that source changes don't invalidate our downloaded layer
    16  RUN go mod download
    17  
    18  COPY . .
    19  
    20  RUN make build
    21  
    22  FROM ubuntu:22.04
    23  
    24  COPY --from=builder /go/src/github.com/matrixorigin/matrixone/mo-service /mo-service
    25  COPY --from=builder /go/src/github.com/matrixorigin/matrixone/etc /etc
    26  
    27  # Install some utilities used for debugging or by startup script
    28  RUN apt-get update && apt-get install -y \
    29      dnsutils \
    30      curl \
    31      git \
    32      && apt-get clean && rm -rf /var/lib/apt/lists/*
    33  
    34  WORKDIR /
    35  
    36  EXPOSE 6001
    37  
    38  ENTRYPOINT [ "/mo-service", "-debug-http=:12345", "-launch", "/etc/quickstart/launch.toml"]