From 5990f0f142b8771865293f06309ea48a8c167695 Mon Sep 17 00:00:00 2001 From: Akihiro Suda Date: Thu, 9 Jan 2020 13:57:01 +0900 Subject: rootlessport: remove state dir on exit Signed-off-by: Akihiro Suda --- pkg/rootlessport/rootlessport_linux.go | 1 + 1 file changed, 1 insertion(+) (limited to 'pkg/rootlessport') diff --git a/pkg/rootlessport/rootlessport_linux.go b/pkg/rootlessport/rootlessport_linux.go index 655d1a448..88105733f 100644 --- a/pkg/rootlessport/rootlessport_linux.go +++ b/pkg/rootlessport/rootlessport_linux.go @@ -105,6 +105,7 @@ func parent() error { if err != nil { return err } + defer os.RemoveAll(stateDir) driver, err := rkbuiltin.NewParentDriver(&logrusWriter{prefix: "parent: "}, stateDir) if err != nil { return err -- cgit v1.2.3-54-g00ecf