diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2020-03-06 07:39:32 -0500 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2020-03-06 10:21:37 -0500 |
commit | cb51707f91e683323ba61fca49363a997ed1be1f (patch) | |
tree | 360c31e8e4d34083f02798cd51ad0ffc435f3b80 /cmd | |
parent | f07e18f05c07026e4544788a1359122c81adcde7 (diff) | |
download | podman-cb51707f91e683323ba61fca49363a997ed1be1f.tar.gz podman-cb51707f91e683323ba61fca49363a997ed1be1f.tar.bz2 podman-cb51707f91e683323ba61fca49363a997ed1be1f.zip |
Allow users to set TMPDIR environment
Some users have small /var/tmp directories and need to be able to specify a different location
for temporary files, which includes more space.
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/podman/load.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/podman/load.go b/cmd/podman/load.go index ed6a4e5fa..318b5b5fb 100644 --- a/cmd/podman/load.go +++ b/cmd/podman/load.go @@ -10,6 +10,7 @@ import ( "github.com/containers/libpod/cmd/podman/cliconfig" "github.com/containers/libpod/cmd/podman/shared/parse" "github.com/containers/libpod/pkg/adapter" + "github.com/containers/libpod/pkg/util" "github.com/pkg/errors" "github.com/spf13/cobra" "golang.org/x/crypto/ssh/terminal" @@ -75,7 +76,7 @@ func loadCmd(c *cliconfig.LoadValues) error { if terminal.IsTerminal(int(os.Stdin.Fd())) { return errors.Errorf("cannot read from terminal. Use command-line redirection or the --input flag.") } - outFile, err := ioutil.TempFile("/var/tmp", "podman") + outFile, err := ioutil.TempFile(util.Tmpdir(), "podman") if err != nil { return errors.Errorf("error creating file %v", err) } |