Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions pkg/asset/cluster/tfvars/tfvars.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (

"github.com/IBM/vpc-go-sdk/vpcv1"
igntypes "github.com/coreos/ignition/v2/config/v3_2/types"
coreosarch "github.com/coreos/stream-metadata-go/arch"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
"k8s.io/utils/ptr"
Expand All @@ -39,7 +38,6 @@ import (
"github.com/openshift/installer/pkg/asset/manifests"
"github.com/openshift/installer/pkg/asset/openshiftinstall"
"github.com/openshift/installer/pkg/asset/rhcos"
rhcospkg "github.com/openshift/installer/pkg/rhcos"
"github.com/openshift/installer/pkg/tfvars"
awstfvars "github.com/openshift/installer/pkg/tfvars/aws"
azuretfvars "github.com/openshift/installer/pkg/tfvars/azure"
Expand Down Expand Up @@ -538,21 +536,6 @@ func (t *TerraformVariables) Generate(ctx context.Context, parents asset.Parents
return fmt.Errorf("failed to create gcp ignition shim: %w", err)
}

archName := coreosarch.RpmArch(string(installConfig.Config.ControlPlane.Architecture))
st, err := rhcospkg.FetchCoreOSBuild(ctx)
if err != nil {
return err
}
streamArch, err := st.GetArchitecture(archName)
if err != nil {
return err
}

img := streamArch.Images.Gcp
if img == nil {
return fmt.Errorf("%s: No GCP build found", st.FormatPrefix(archName))
}

tags, err := gcpconfig.NewTagManager(client).GetUserTags(ctx,
installConfig.Config.Platform.GCP.ProjectID,
installConfig.Config.Platform.GCP.UserTags)
Expand Down
2 changes: 2 additions & 0 deletions pkg/types/installconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -583,6 +583,8 @@ func MultiArchFeatureGateEnabled(platform string, fgs featuregates.FeatureGate)
switch platform {
case aws.Name:
return fgs.Enabled(features.FeatureGateMultiArchInstallAWS)
case gcp.Name:
return fgs.Enabled(features.FeatureGateMultiArchInstallGCP)
default:
return false
}
Expand Down
11 changes: 11 additions & 0 deletions pkg/types/validation/installconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1423,6 +1423,17 @@ func TestValidateInstallConfig(t *testing.T) {
return c
}(),
},
{
name: "gcp cluster is heteregeneous",
installConfig: func() *types.InstallConfig {
c := validInstallConfig()
c.Platform = types.Platform{GCP: validGCPPlatform()}
c.Compute[0].Architecture = types.ArchitectureARM64
c.FeatureSet = "CustomNoUpgrade"
c.FeatureGates = []string{"MultiArchInstallGCP=true"}
return c
}(),
},
{
name: "valid cloud credentials mode",
installConfig: func() *types.InstallConfig {
Expand Down