diff --git a/docker/w9deployment/Dockerfile b/docker/w9deployment/Dockerfile index d3427c12..2e3fe17c 100644 --- a/docker/w9deployment/Dockerfile +++ b/docker/w9deployment/Dockerfile @@ -9,4 +9,6 @@ RUN chmod +x /init_portainer FROM portainer/portainer-ce:2.19.0 LABEL maintainer="websoft9" LABEL version="2.19.0" -COPY --from=builder /init_portainer / \ No newline at end of file +COPY --from=builder /init_portainer / + +ENTRYPOINT ["/init_portainer"] \ No newline at end of file diff --git a/docker/w9deployment/init_portainer.go b/docker/w9deployment/init_portainer.go index 9dbbaa18..5bf50e75 100644 --- a/docker/w9deployment/init_portainer.go +++ b/docker/w9deployment/init_portainer.go @@ -39,6 +39,9 @@ func main() { fmt.Println("write file error:", err) return } + }else{ + cmd := exec.Command("./portainer") + cmd.Run() } content, err := ioutil.ReadFile(filePath)