Check dockerinit only if lxc driver is used

This allow you to run dynamically linked docker without compiling
dockerinit.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: 96bc377a8d293cf786722ebb0ff89a81d63e43ed
Component: engine
This commit is contained in:
Alexander Morozov
2015-07-08 14:12:49 -07:00
parent f9a4f23ebb
commit 48bfe58a0d

View File

@ -698,9 +698,13 @@ func NewDaemon(config *Config, registryService *registry.Service) (daemon *Daemo
d.containerGraph = graph
sysInitPath, err := configureSysInit(config)
if err != nil {
return nil, err
var sysInitPath string
if config.ExecDriver == "lxc" {
initPath, err := configureSysInit(config)
if err != nil {
return nil, err
}
sysInitPath = initPath
}
sysInfo := sysinfo.New(false)