diff options
author | Giuseppe Scrivano <gscrivan@redhat.com> | 2019-08-13 14:33:57 +0200 |
---|---|---|
committer | Giuseppe Scrivano <gscrivan@redhat.com> | 2019-08-13 21:43:36 +0200 |
commit | 04d333f0efd0d1af78785c76ed357f0fa98cafa1 (patch) | |
tree | 001a8ddfecbf40ba6b236a54bc1d56da56e58c0b /pkg/adapter/runtime.go | |
parent | 231b6cb7581a3a78345a7d7ac47129d6df44813a (diff) | |
download | podman-04d333f0efd0d1af78785c76ed357f0fa98cafa1.tar.gz podman-04d333f0efd0d1af78785c76ed357f0fa98cafa1.tar.bz2 podman-04d333f0efd0d1af78785c76ed357f0fa98cafa1.zip |
runtime: honor --runtime flag to build
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'pkg/adapter/runtime.go')
-rw-r--r-- | pkg/adapter/runtime.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/pkg/adapter/runtime.go b/pkg/adapter/runtime.go index 03419c0bd..c80d5991e 100644 --- a/pkg/adapter/runtime.go +++ b/pkg/adapter/runtime.go @@ -288,7 +288,11 @@ func (r *LocalRuntime) Build(ctx context.Context, c *cliconfig.BuildValues, opti options.CommonBuildOpts = commonOpts options.SystemContext = systemContext - options.Runtime = r.GetOCIRuntimePath() + if c.GlobalFlags.Runtime != "" { + options.Runtime = c.GlobalFlags.Runtime + } else { + options.Runtime = r.GetOCIRuntimePath() + } if c.Quiet { options.ReportWriter = ioutil.Discard |