mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
LINKED CONTAINER ID PASSED TO LXC
This passed the --net=container:CONTINER_ID to lxc-start as --share-net Docker-DCO-1.1-Signed-off-by: Abin Shahab <ashahab@altiscale.com> (github: ashahab-altiscale)
This commit is contained in:
parent
e546c8cc1d
commit
adb07b53e0
1 changed files with 9 additions and 2 deletions
|
@ -86,10 +86,17 @@ func (d *driver) Run(c *execdriver.Command, pipes *execdriver.Pipes, startCallba
|
||||||
"lxc-start",
|
"lxc-start",
|
||||||
"-n", c.ID,
|
"-n", c.ID,
|
||||||
"-f", configPath,
|
"-f", configPath,
|
||||||
"--",
|
}
|
||||||
c.InitPath,
|
if c.Network.ContainerID != "" {
|
||||||
|
params = append(params,
|
||||||
|
"--share-net", c.Network.ContainerID,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
params = append(params,
|
||||||
|
"--",
|
||||||
|
c.InitPath,
|
||||||
|
)
|
||||||
if c.Network.Interface != nil {
|
if c.Network.Interface != nil {
|
||||||
params = append(params,
|
params = append(params,
|
||||||
"-g", c.Network.Interface.Gateway,
|
"-g", c.Network.Interface.Gateway,
|
||||||
|
|
Loading…
Add table
Reference in a new issue