summaryrefslogtreecommitdiff
path: root/cmd/podman/libpodruntime
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2018-07-11 09:38:04 +0200
committerGiuseppe Scrivano <gscrivan@redhat.com>2018-07-11 09:38:04 +0200
commit340becf542b240f82ffda0fe998da334a3ffbd0b (patch)
tree0e6ceff916c036ae2b6686b8113f12271bc44986 /cmd/podman/libpodruntime
parent7e3c0d493e1afbae284071643d1a46c571776a04 (diff)
downloadpodman-340becf542b240f82ffda0fe998da334a3ffbd0b.tar.gz
podman-340becf542b240f82ffda0fe998da334a3ffbd0b.tar.bz2
podman-340becf542b240f82ffda0fe998da334a3ffbd0b.zip
rootless: propagate errors from GetRootlessRuntimeDir()
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'cmd/podman/libpodruntime')
-rw-r--r--cmd/podman/libpodruntime/runtime.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/cmd/podman/libpodruntime/runtime.go b/cmd/podman/libpodruntime/runtime.go
index e8177d5ee..098864810 100644
--- a/cmd/podman/libpodruntime/runtime.go
+++ b/cmd/podman/libpodruntime/runtime.go
@@ -24,7 +24,11 @@ func GetRuntime(c *cli.Context) (*libpod.Runtime, error) {
func GetRootlessStorageOpts() (storage.StoreOptions, error) {
var opts storage.StoreOptions
- opts.RunRoot = filepath.Join(libpod.GetRootlessRuntimeDir(), "run")
+ rootlessRuntime, err := libpod.GetRootlessRuntimeDir()
+ if err != nil {
+ return opts, err
+ }
+ opts.RunRoot = filepath.Join(rootlessRuntime, "run")
dataDir := os.Getenv("XDG_DATA_HOME")
if dataDir == "" {