diff --git a/snap/1185-runtime.patch b/snap/1185-runtime.patch new file mode 100644 index 0000000000..a256ed107b --- /dev/null +++ b/snap/1185-runtime.patch @@ -0,0 +1,22 @@ +diff --git a/cli/main.go b/cli/main.go +index a01a02dc5..a021a0a77 100644 +--- a/cli/main.go ++++ b/cli/main.go +@@ -250,6 +250,8 @@ func beforeSubcommands(c *cli.Context) error { + var runtimeConfig oci.RuntimeConfig + var err error + ++ katautils.SetConfigOptions(name, defaultRuntimeConfiguration, defaultSysConfRuntimeConfiguration) ++ + handleShowConfig(c) + + if userWantsUsage(c) || (c.NArg() == 1 && (c.Args()[0] == checkCmd)) { +@@ -302,8 +304,6 @@ func beforeSubcommands(c *cli.Context) error { + ignoreLogging = true + } + +- katautils.SetConfigOptions(name, defaultRuntimeConfiguration, defaultSysConfRuntimeConfiguration) +- + configFile, runtimeConfig, err = katautils.LoadConfiguration(c.GlobalString(configFilePathOption), ignoreLogging, false) + if err != nil { + fatal(err) diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index a9c7d21621..9dd170653a 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -34,6 +34,7 @@ parts: override-build: | pkg_name=runtime patch1="$(realpath ../../../snap/1162-runtime.patch)" + patch2="$(realpath ../../../snap/1185-runtime.patch)" # set GOPATH export GOPATH=$(realpath go) @@ -49,6 +50,8 @@ parts: #Issue: https://github.com/kata-containers/runtime/pull/1162 patch -p1 < "${patch1}" + #Issue: https://github.com/kata-containers/runtime/issues/1185 + patch -p1 < "${patch2}" # build and install make \