[lxc] default to target runlevel 3

pull/3523/head
Chris Lundquist 10 years ago
parent 9492e1a5e3
commit b4bc312067

@ -50,6 +50,10 @@ func NewConfig(raws ...interface{}) (*Config, error) {
c.ContainerName = fmt.Sprintf("packer-%s", c.PackerBuildName)
}
if c.TargetRunlevel == 0 {
c.TargetRunlevel = 3
}
if c.CommandWrapper == "" {
c.CommandWrapper = "{{.Command}}"
}

@ -93,7 +93,7 @@ func (s *StepWaitInit) waitForInit(state multistep.StateBag, cancel <-chan struc
log.Printf("Container finished init.")
break
} else if currentRunlevel > targetRunlevel {
log.Printf("Expected Runlevel %d, Got Runlevel %s, continuing", targetRunlevel, currentRunlevel)
log.Printf("Expected Runlevel %s, Got Runlevel %s, continuing", targetRunlevel, currentRunlevel)
break
}

Loading…
Cancel
Save