This is an automated email from the ASF dual-hosted git repository. pcongiusti pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-k.git
commit 350c5fb1f80aeba11921ee1dbf0ec9558db98338 Author: Gaelle Fournier <[email protected]> AuthorDate: Tue Apr 4 17:46:29 2023 +0200 fix(core): Fix copy local dependencies error message Change copy option to avoid trying to change the permissions on the target folder Closes #4198 --- pkg/install/optional.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pkg/install/optional.go b/pkg/install/optional.go index a5a1e4c6a..3dc52a945 100644 --- a/pkg/install/optional.go +++ b/pkg/install/optional.go @@ -30,7 +30,12 @@ import ( // OperatorStartupOptionalTools tries to install optional tools at operator startup and warns if something goes wrong. func OperatorStartupOptionalTools(ctx context.Context, c client.Client, namespace string, operatorNamespace string, log logutil.Logger) { // Try to copy any local runtime dependency to maven repository - if err := cp.Copy("/tmp/local/m2", defaults.LocalRepository); err != nil { + + // Do not change the permissions on the target + opt := cp.Options{ + PermissionControl: cp.DoNothing, + } + if err := cp.Copy("/tmp/local/m2", defaults.LocalRepository, opt); err != nil { log.Infof("Could not copy local runtime dependencies due to %s", err.Error()) }
