1
0
mirror of https://github.com/bingohuang/docker-labs.git synced 2025-07-15 02:37:27 +08:00

Add container names to make attachable names work

This commit is contained in:
Marcos Lilljedahl 2016-11-21 22:01:00 -03:00
parent a7d76f2720
commit 8f5f9f2c90

View File

@ -94,7 +94,7 @@ func CreateInstance(session *Session, dindImage string) (*Instance, error) {
session.Id: &network.EndpointSettings{Aliases: []string{nodeName}},
},
}
container, err := c.ContainerCreate(context.Background(), conf, h, networkConf, "")
container, err := c.ContainerCreate(context.Background(), conf, h, networkConf, fmt.Sprintf("%s_%s", session.Id[:4], nodeName))
if err != nil {
return nil, err