mirror of https://github.com/containers/podman.git
Merge pull request #12685 from mheon/handle_nil_passwd
Always run passwd management code when DB value is nil
This commit is contained in:
commit
74a58faf2a
|
@ -1763,7 +1763,7 @@ func (c *Container) makeBindMounts() error {
|
||||||
// SHM is always added when we mount the container
|
// SHM is always added when we mount the container
|
||||||
c.state.BindMounts["/dev/shm"] = c.config.ShmDir
|
c.state.BindMounts["/dev/shm"] = c.config.ShmDir
|
||||||
|
|
||||||
if c.config.Passwd != nil && *c.config.Passwd {
|
if c.config.Passwd == nil || *c.config.Passwd {
|
||||||
newPasswd, newGroup, err := c.generatePasswdAndGroup()
|
newPasswd, newGroup, err := c.generatePasswdAndGroup()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return errors.Wrapf(err, "error creating temporary passwd file for container %s", c.ID())
|
return errors.Wrapf(err, "error creating temporary passwd file for container %s", c.ID())
|
||||||
|
|
Loading…
Reference in New Issue