mirror of
https://github.com/docker/cli.git
synced 2026-01-23 15:21:32 +03:00
Merge pull request #15635 from cpuguy83/15633_allow_logconfig_empty_driver
Fix `inspect` output when no log driver specified Upstream-commit: 5aeb48af7702be78774c36cfabbda1b3bf1c7b34 Component: engine
This commit is contained in:
@@ -38,7 +38,11 @@ func (daemon *Daemon) getInspectData(container *Container) (*types.ContainerJSON
|
||||
// we need this trick to preserve empty log driver, so
|
||||
// container will use daemon defaults even if daemon change them
|
||||
if hostConfig.LogConfig.Type == "" {
|
||||
hostConfig.LogConfig = daemon.defaultLogConfig
|
||||
hostConfig.LogConfig.Type = daemon.defaultLogConfig.Type
|
||||
}
|
||||
|
||||
if hostConfig.LogConfig.Config == nil {
|
||||
hostConfig.LogConfig.Config = daemon.defaultLogConfig.Config
|
||||
}
|
||||
|
||||
containerState := &types.ContainerState{
|
||||
|
||||
Reference in New Issue
Block a user