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-18 09:31:29 +08:00
|
|
|
LABEL maintainer="websoft9<help@websoft9.com>"
|
2023-09-18 09:01:53 +08:00
|
|
|
LABEL version="2.19.0"
|
2023-09-13 08:38:24 +08:00
|
|
|
COPY --from=builder /init_portainer /
|