ledo/app/modules/interact/docker_init.go

25 lines
416 B
Go
Raw Normal View History

2021-11-28 00:04:20 +00:00
package interact
import (
"ledo/app/helper"
)
func InitDocker() (helper.DockerProjectCfg, error) {
dockerConfig := helper.DockerProjectCfg{}
image, err := EnterDockerImage()
if err != nil {
return dockerConfig, err
}
tag, err := SelectDockerHubTag(image)
if err != nil {
return dockerConfig, err
}
dockerConfig.DockerBaseImage = image
dockerConfig.DockerBaseTag = tag
return dockerConfig, err
}