mirror of
https://github.com/clearlinux/docker.git
synced 2026-08-19 12:16:30 +00:00
@@ -168,6 +168,9 @@ func (d *driver) Run(c *execdriver.Command, pipes *execdriver.Pipes, startCallba
|
||||
// Poll lxc for RUNNING status
|
||||
pid, err := d.waitForStart(c, waitLock)
|
||||
if err != nil {
|
||||
if c.Process != nil {
|
||||
c.Process.Kill()
|
||||
}
|
||||
return -1, err
|
||||
}
|
||||
c.ContainerPid = pid
|
||||
|
||||
@@ -36,7 +36,7 @@ func parseLxcInfo(raw string) (*lxcInfo, error) {
|
||||
if len(parts) < 2 {
|
||||
continue
|
||||
}
|
||||
switch strings.TrimSpace(parts[0]) {
|
||||
switch strings.ToLower(strings.TrimSpace(parts[0])) {
|
||||
case "state":
|
||||
info.Running = strings.TrimSpace(parts[1]) == "RUNNING"
|
||||
case "pid":
|
||||
|
||||
Reference in New Issue
Block a user