package portaineree import ( "ocl/portainer-devtool/configs" "ocl/portainer-devtool/tasks/common" "ocl/portainer-devtool/utils" ) type BuildDockerImageSubTask struct { common.GeneralTask } func NewBuildDockerImageSubTask(cfg *configs.Config) *BuildDockerImageSubTask { return &BuildDockerImageSubTask{ GeneralTask: *common.NewGeneralTask(cfg), } } func (task *BuildDockerImageSubTask) Execute() error { utils.SuccessPrint(` yarn build docker build -t "portainerci/portainer:ee4803" -f build/linux/Dockerfile . docker run -d -p 8000:8000 -p 9443:9443 --name portainer --restart=always -v "/var/run/docker.sock:/var/run/docker.sock" -v ${env:HOME}/volume/portainer-ee-data-2:/data --add-host=host.docker.internal:host-gateway portainerci/portainer:ee4803 `) return nil } func (task *BuildDockerImageSubTask) String() string { return "Build Docker Image" }