diff options
author | Ryan Gonzalez <rymg19@gmail.com> | 2019-01-21 13:35:06 -0600 |
---|---|---|
committer | Matthew Heon <matthew.heon@pm.me> | 2019-02-08 15:02:28 -0500 |
commit | c5f408b00887c0c3130e06b5dc234a6b0ca99b2d (patch) | |
tree | d0f7d34979b4a2622f124effef074b19560b017c /libpod | |
parent | 14eaca337af0fe3c66624a1a808157b6de8bff68 (diff) | |
download | podman-c5f408b00887c0c3130e06b5dc234a6b0ca99b2d.tar.gz podman-c5f408b00887c0c3130e06b5dc234a6b0ca99b2d.tar.bz2 podman-c5f408b00887c0c3130e06b5dc234a6b0ca99b2d.zip |
Show a better error message when podman info fails during a refresh
Signed-off-by: Ryan Gonzalez <rymg19@gmail.com>
Diffstat (limited to 'libpod')
-rw-r--r-- | libpod/runtime.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libpod/runtime.go b/libpod/runtime.go index facbe5d66..11c90166d 100644 --- a/libpod/runtime.go +++ b/libpod/runtime.go @@ -772,7 +772,11 @@ func (r *Runtime) refreshRootless() error { // Take advantage of a command that requires a new userns // so that we are running as the root user and able to use refresh() cmd := exec.Command(os.Args[0], "info") - return cmd.Run() + err := cmd.Run() + if err != nil { + return errors.Wrapf(err, "Error running %s info while refreshing state", os.Args[0]) + } + return nil } // Reconfigures the runtime after a reboot |