summaryrefslogtreecommitdiff
path: root/pkg/rootlessport
diff options
context:
space:
mode:
authorAkihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>2020-01-09 14:06:33 +0900
committerAkihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>2020-01-09 14:06:33 +0900
commit556cc1fadf9a65da20dcc1e4ef0fa2523850cf7e (patch)
tree6209f8e6358720e8cdd411cbcd5beb409c1e0e81 /pkg/rootlessport
parent5990f0f142b8771865293f06309ea48a8c167695 (diff)
downloadpodman-556cc1fadf9a65da20dcc1e4ef0fa2523850cf7e.tar.gz
podman-556cc1fadf9a65da20dcc1e4ef0fa2523850cf7e.tar.bz2
podman-556cc1fadf9a65da20dcc1e4ef0fa2523850cf7e.zip
rootlessport: honor ctr.runtime.config.TmpDir
Previously, rootlessport was using /var/tmp as the tmp dir. Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
Diffstat (limited to 'pkg/rootlessport')
-rw-r--r--pkg/rootlessport/rootlessport_linux.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/rootlessport/rootlessport_linux.go b/pkg/rootlessport/rootlessport_linux.go
index 88105733f..3e678d33a 100644
--- a/pkg/rootlessport/rootlessport_linux.go
+++ b/pkg/rootlessport/rootlessport_linux.go
@@ -46,6 +46,7 @@ type Config struct {
NetNSPath string
ExitFD int
ReadyFD int
+ TmpDir string
}
func init() {
@@ -101,7 +102,7 @@ func parent() error {
}
// create the parent driver
- stateDir, err := ioutil.TempDir("", "rootlessport")
+ stateDir, err := ioutil.TempDir(cfg.TmpDir, "rootlessport")
if err != nil {
return err
}