fix: 修复了部分容器创建完直接退出的问题 (#432)

pull/433/head
ssongliu 2 years ago committed by GitHub
parent e2d39b9ed0
commit b454c959b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -156,10 +156,12 @@ func (u *ContainerService) ContainerCreate(req dto.ContainerCreate) error {
return err return err
} }
config := &container.Config{ config := &container.Config{
Image: req.Image, Image: req.Image,
Cmd: req.Cmd, Cmd: req.Cmd,
Env: req.Env, Env: req.Env,
Labels: stringsToMap(req.Labels), Labels: stringsToMap(req.Labels),
Tty: true,
OpenStdin: true,
} }
hostConf := &container.HostConfig{ hostConf := &container.HostConfig{
AutoRemove: req.AutoRemove, AutoRemove: req.AutoRemove,

Loading…
Cancel
Save