From 70fe2a1c9566b244132cf118001d934000cea0f4 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Fri, 22 Mar 2024 11:46:38 +0100 Subject: [PATCH] fix remote build isolation on client side Follow up to 493179be45 which only fixed the issue on the server despite me trying to fix it on the client as well, with this change here we always correctly unset the default on the remote client as the root/rootless status will be wrong. This means it is enough for users to either have a new server or client with the bug fix which should make the update process easier. Signed-off-by: Paul Holzinger --- cmd/podman/common/build.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/podman/common/build.go b/cmd/podman/common/build.go index 25be5154e8..c34055615c 100644 --- a/cmd/podman/common/build.go +++ b/cmd/podman/common/build.go @@ -113,6 +113,9 @@ func DefineBuildFlags(cmd *cobra.Command, buildOpts *BuildFlagsWrapper, isFarmBu completion.CompleteCommandFlags(cmd, fromAndBudFlagsCompletions) flags.SetNormalizeFunc(buildahCLI.AliasFlags) if registry.IsRemote() { + // Unset the isolation default as we never want to send this over the API + // as it can be wrong (root vs rootless). + _ = flags.Lookup("isolation").Value.Set("") _ = flags.MarkHidden("disable-content-trust") _ = flags.MarkHidden("sign-by") _ = flags.MarkHidden("signature-policy")