From 93135565914c17eae64b81855e72526fe6c80e66 Mon Sep 17 00:00:00 2001 From: Peter Hunt Date: Sat, 8 Jun 2019 17:44:44 -0400 Subject: only set log driver if it isn't empty Now, not setting a log driver in a create config correctly takes the default (k8s-logging) Signed-off-by: Peter Hunt --- pkg/spec/createconfig.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'pkg/spec/createconfig.go') diff --git a/pkg/spec/createconfig.go b/pkg/spec/createconfig.go index e4501aaac..ed8036a54 100644 --- a/pkg/spec/createconfig.go +++ b/pkg/spec/createconfig.go @@ -320,7 +320,9 @@ func (c *CreateConfig) getContainerCreateOptions(runtime *libpod.Runtime, pod *l options = append(options, libpod.WithLogPath(logPath)) } - options = append(options, libpod.WithLogDriver(c.LogDriver)) + if c.LogDriver != "" { + options = append(options, libpod.WithLogDriver(c.LogDriver)) + } if c.IPAddress != "" { ip := net.ParseIP(c.IPAddress) -- cgit v1.2.3-54-g00ecf