Skip to content

Commit

Permalink
HOSTEDCP-1981: Add controlplane cli image envar for use with hypershift
Browse files Browse the repository at this point in the history
Add CLI_CONTROL_PLANE_IMAGE enavr to
cloud-network, multus-admission-controller and node-identity to avoid
registryOverrides propagating to data plane components
  • Loading branch information
Patryk-Stefanski committed Sep 26, 2024
1 parent d936ce3 commit 2ab159e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/network/cloud_network.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func renderCloudNetworkConfigController(conf *operv1.NetworkSpec, bootstrapResul
manifestDirs := make([]string, 0, 2)
manifestDirs = append(manifestDirs, filepath.Join(manifestDir, "cloud-network-config-controller/common"))
if hcpCfg := hypershift.NewHyperShiftConfig(); hcpCfg.Enabled {
data.Data["CLIImage"] = os.Getenv("CLI_IMAGE")
data.Data["CLIImage"] = os.Getenv("CLI_CONTROL_PLANE_IMAGE")
data.Data["TokenMinterImage"] = os.Getenv("TOKEN_MINTER_IMAGE")
data.Data["TokenAudience"] = os.Getenv("TOKEN_AUDIENCE")
data.Data["ManagementClusterName"] = names.ManagementClusterName
Expand Down
2 changes: 1 addition & 1 deletion pkg/network/multus_admission_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ func renderMultusAdmissonControllerConfig(manifestDir string, externalControlPla
data.Data["AdmissionControllerNamespace"] = hsc.Namespace
data.Data["KubernetesServiceHost"] = bootstrapResult.Infra.APIServers[bootstrap.APIServerDefaultLocal].Host
data.Data["KubernetesServicePort"] = bootstrapResult.Infra.APIServers[bootstrap.APIServerDefaultLocal].Port
data.Data["CLIImage"] = os.Getenv("CLI_IMAGE")
data.Data["CLIImage"] = os.Getenv("CLI_CONTROL_PLANE_IMAGE")
data.Data["TokenMinterImage"] = os.Getenv("TOKEN_MINTER_IMAGE")
data.Data["TokenAudience"] = os.Getenv("TOKEN_AUDIENCE")
data.Data["RunAsUser"] = hsc.RunAsUser
Expand Down
2 changes: 1 addition & 1 deletion pkg/network/node_identity.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ func renderNetworkNodeIdentity(conf *operv1.NetworkSpec, bootstrapResult *bootst
data.Data["NetworkNodeIdentityReplicas"] = 3
}
data.Data["ReleaseImage"] = hcpCfg.ReleaseImage
data.Data["CLIImage"] = os.Getenv("CLI_IMAGE")
data.Data["CLIImage"] = os.Getenv("CLI_CONTROL_PLANE_IMAGE")
data.Data["TokenMinterImage"] = os.Getenv("TOKEN_MINTER_IMAGE")
data.Data["TokenAudience"] = os.Getenv("TOKEN_AUDIENCE")
data.Data["HCPNodeSelector"] = bootstrapResult.Infra.HostedControlPlane.NodeSelector
Expand Down

0 comments on commit 2ab159e

Please sign in to comment.