websoft9/docker/w9deploy/Dockerfile

10 lines
328 B
Docker
Raw Normal View History

2023-09-11 08:40:56 +08:00
# step1: build entrypoint execute program init_portainer by golang
FROM golang:latest AS builder
WORKDIR /
2023-09-11 16:51:48 +08:00
COPY init_portainer.go /
RUN go build -o init_portainer /init_portainer.go
2023-09-13 08:38:24 +08:00
RUN chmod +x /init_portainer
2023-09-11 08:40:56 +08:00
# step2: copy build go program to portainer
FROM portainer/portainer-ce:2.19.0
2023-09-13 08:38:24 +08:00
COPY --from=builder /init_portainer /