diff options
Diffstat (limited to 'libpod/container.go')
-rw-r--r-- | libpod/container.go | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libpod/container.go b/libpod/container.go index fa90fef7a..f7abfb005 100644 --- a/libpod/container.go +++ b/libpod/container.go @@ -278,6 +278,9 @@ type ContainerConfig struct { User string `json:"user,omitempty"` // Additional groups to add Groups []string `json:"groups,omitempty"` + // AddCurrentUserPasswdEntry indicates that the current user passwd entry + // should be added to the /etc/passwd within the container + AddCurrentUserPasswdEntry bool `json:"addCurrentUserPasswdEntry,omitempty"` // Namespace Config // IDs of container to share namespaces with @@ -786,7 +789,10 @@ func (c *Container) Hostname() string { // WorkingDir returns the containers working dir func (c *Container) WorkingDir() string { - return c.config.Spec.Process.Cwd + if c.config.Spec.Process != nil { + return c.config.Spec.Process.Cwd + } + return "/" } // State Accessors |