diff options
Diffstat (limited to 'libpod/container_internal.go')
-rw-r--r-- | libpod/container_internal.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libpod/container_internal.go b/libpod/container_internal.go index d70e5c13b..0b04cc81a 100644 --- a/libpod/container_internal.go +++ b/libpod/container_internal.go @@ -673,13 +673,14 @@ func (c *Container) makeBindMounts() error { } // Make .containerenv - if _, ok := c.state.BindMounts["/.containerenv"]; !ok { + // Empty file, so no need to recreate if it exists + if _, ok := c.state.BindMounts["/run/.containerenv"]; !ok { // Empty string for now, but we may consider populating this later containerenvPath, err := c.writeStringToRundir(".containerenv", "") if err != nil { return errors.Wrapf(err, "error creating containerenv file for container %s", c.ID()) } - c.state.BindMounts["/.containerenv"] = containerenvPath + c.state.BindMounts["/run/.containerenv"] = containerenvPath } return nil |