From bc6695d61d2bb6801e6f60e4f73681045edd9db1 Mon Sep 17 00:00:00 2001 From: Maninderjit Bindra Date: Mon, 23 Oct 2023 11:32:32 +0530 Subject: [PATCH 1/7] Add mount host volume action argument - Fixes #475 - Add option to mount host volume Signed-off-by: Maninderjit Bindra --- cmd/porter/installations.go | 1 + pkg/cnab/provider/action.go | 9 ++ pkg/cnab/provider/docker_linux.go | 11 ++ pkg/cnab/provider/driver.go | 60 +++++++--- pkg/cnab/provider/driver_darwin.go | 11 ++ pkg/cnab/provider/driver_test.go | 178 ++++++++++++++++++++++++++++ pkg/cnab/provider/driver_windows.go | 11 ++ pkg/porter/lifecycle.go | 40 +++++++ pkg/porter/lifecycle_test.go | 64 ++++++++++ 9 files changed, 371 insertions(+), 14 deletions(-) diff --git a/cmd/porter/installations.go b/cmd/porter/installations.go index 2d9daedc2..94105b77b 100644 --- a/cmd/porter/installations.go +++ b/cmd/porter/installations.go @@ -418,6 +418,7 @@ func addBundleActionFlags(f *pflag.FlagSet, actionOpts porter.BundleAction) { addBundlePullFlags(f, &opts.BundlePullOptions) f.BoolVar(&opts.AllowDockerHostAccess, "allow-docker-host-access", false, "Controls if the bundle should have access to the host's Docker daemon with elevated privileges. See https://getporter.org/configuration/#allow-docker-host-access for the full implications of this flag.") + f.StringArrayVar(&opts.HostVolumeMounts, "mount-host-volume", nil, "Mount a host volume into the bundle. Format is :[: