Skip to content

Commit

Permalink
[PLT-806,PLT-911,PLT-917,PLT-920] Multiples Cherry Picks (Stratio#610)
Browse files Browse the repository at this point in the history
* [PLT-806] GKE nodos privados (Stratio#602)

* First approach GKE Private

* Rollback version

* Remove debug and so on

* Update changes

* Update changes

* Update changes

* Change version to pre-elease (Stratio#605)

* [PLT-917] Replace coredns yaml files with a single coredns tmpl file (Stratio#606)

* replace coredns yaml files with a single coredns tmpl file

* remove old coredns files references

* fixed capg version in GKE with private registry

* [PLT-920] Added use-local-stratio-image flag to reuse local image (Stratio#607)

* Added use-local-stratio-image flag to reuse local image

* refactored steps

---------

Co-authored-by: Antonio López <[email protected]>

* Update CHANGELOG.md (Stratio#609)

* refactored code and aligned GKE changes

* refactored code and aligned GKE changes

* refactored code and aligned GKE changes

* Fix CHANGELOG.md (Stratio#612)

---------

Co-authored-by: José Alberto Novoa Rojas <[email protected]>
Co-authored-by: Antonio López <[email protected]>
  • Loading branch information
3 people authored Oct 16, 2024
1 parent c1b11db commit 336682a
Show file tree
Hide file tree
Showing 20 changed files with 670 additions and 308 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@
* [Core] Support k8s v1.30
* [Core] Deprecated Kubernetes versions prior to 1.28
* [PLT-817] Bump Tigera Operator version to v3.28.2
* [PLT-806] Support for private clusters on GKE
* [PLT-920] Added use-local-stratio-image flag to reuse local image
* [PLT-917] Replace coredns yaml files with a single coredns tmpl file
* [PLT-929] Removed calico installation as policy manager by helm chart in GKE
* [PLT-911] Support for Disable External Endpoint in GKE

## 0.17.0-0.5.3 (2024-09-24)

* [Core] Adapted for GKE support

## 0.17.0-0.5.2 (2024-06-25)

Expand Down
44 changes: 22 additions & 22 deletions pkg/cluster/internal/create/actions/createworker/aws.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,41 +112,41 @@ var awsCharts = ChartsDictionary{
Charts: map[string]map[string]map[string]commons.ChartEntry{
"28": {
"managed": {
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.0", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: false},
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: false, Reconcile: false},
},
"unmanaged": {
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true},
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true, Reconcile: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
"29": {
"managed": {
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.0", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: false},
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: false, Reconcile: false},
},
"unmanaged": {
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true},
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true, Reconcile: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
"30": {
"managed": {
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.1", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: false},
"aws-load-balancer-controller": {Repository: "https://aws.github.io/eks-charts", Version: "1.8.1", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: false, Reconcile: false},
},
"unmanaged": {
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: true},
"aws-cloud-controller-manager": {Repository: "https://kubernetes.github.io/cloud-provider-aws", Version: "0.0.8", Namespace: "kube-system", Pull: true, Reconcile: true},
"aws-ebs-csi-driver": {Repository: "https://kubernetes-sigs.github.io/aws-ebs-csi-driver", Version: "2.31.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
},
Expand Down Expand Up @@ -254,7 +254,7 @@ func (b *AWSBuilder) installCSI(n nodes.Node, k string, privateParams PrivatePar
if getManifestErr != nil {
return errors.Wrap(getManifestErr, "failed to generate "+csiName+"-csi helm values")
}

c := "echo '" + csiHelmValues + "' > " + csiValuesFile
_, err := commons.ExecuteCommand(n, c, 5, 3)
if err != nil {
Expand Down
54 changes: 27 additions & 27 deletions pkg/cluster/internal/create/actions/createworker/azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,31 +59,31 @@ var azureCharts = ChartsDictionary{
"28": {
"managed": {},
"unmanaged": {
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.28.7", Pull: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.28.7", Pull: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.28.5", Pull: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true},
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.28.7", Pull: false, Reconcile: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.28.7", Pull: false, Reconcile: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.28.5", Pull: true, Reconcile: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.34.1", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
"29": {
"managed": {},
"unmanaged": {
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.29.5", Pull: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.29.5", Pull: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.29.0", Pull: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true},
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.29.5", Pull: false, Reconcile: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.29.5", Pull: false, Reconcile: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.29.0", Pull: true, Reconcile: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.35.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.2", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
"30": {
"managed": {},
"unmanaged": {
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.30.1", Pull: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.30.2", Pull: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.30.4", Pull: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: true},
"azuredisk-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azuredisk-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.30.1", Pull: false, Reconcile: false},
"azurefile-csi-driver": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/azurefile-csi-driver/master/charts", Namespace: "kube-system", Version: "v1.30.2", Pull: false, Reconcile: false},
"cloud-provider-azure": {Repository: "https://raw.githubusercontent.com/kubernetes-sigs/cloud-provider-azure/master/helm/repo", Namespace: "kube-system", Version: "v1.30.4", Pull: true, Reconcile: true},
"cluster-autoscaler": {Repository: "https://kubernetes.github.io/autoscaler", Version: "9.37.0", Namespace: "kube-system", Pull: false, Reconcile: false},
"tigera-operator": {Repository: "https://docs.projectcalico.org/charts", Version: "v3.28.0", Namespace: "tigera-operator", Pull: true, Reconcile: true},
},
},
},
Expand Down Expand Up @@ -227,7 +227,7 @@ func (b *AzureBuilder) installCSI(n nodes.Node, kubeconfigPath string, privatePa
if !privateParams.KeosCluster.Spec.ControlPlane.Managed {
var ctx = context.Background()
azureDiskSecretFile := "/kind/azuredisk-azure.json"
azureDiskNamespace := chartsList["azuredisk-csi-driver"].Namespace
azureDiskNamespace := chartsList["azuredisk-csi-driver"].Namespace
nodesIdentity := privateParams.KeosCluster.Spec.Security.NodesIdentity

matchResourceGroup := strings.Split(nodesIdentity, "resourceGroups/")
Expand Down Expand Up @@ -265,18 +265,18 @@ func (b *AzureBuilder) installCSI(n nodes.Node, kubeconfigPath string, privatePa
objectIDIdentity := *managedIdentity.Properties.ClientID

azureDiskParams := struct {
TenantID string
SubscriptionID string
KeosClusterName string
Region string
Networks commons.Networks
TenantID string
SubscriptionID string
KeosClusterName string
Region string
Networks commons.Networks
UserAssignedIdentityID string
}{
TenantID: providerParams.Credentials["TenantID"],
SubscriptionID: providerParams.Credentials["SubscriptionID"],
KeosClusterName: providerParams.ClusterName,
Region: providerParams.Region,
Networks: privateParams.KeosCluster.Spec.Networks,
TenantID: providerParams.Credentials["TenantID"],
SubscriptionID: providerParams.Credentials["SubscriptionID"],
KeosClusterName: providerParams.ClusterName,
Region: providerParams.Region,
Networks: privateParams.KeosCluster.Spec.Networks,
UserAssignedIdentityID: objectIDIdentity,
}

Expand All @@ -291,7 +291,7 @@ func (b *AzureBuilder) installCSI(n nodes.Node, kubeconfigPath string, privatePa
return errors.Wrap(err, "failed to create azuredisk driver config")
}
c = "kubectl --kubeconfig " + kubeconfigPath + " create secret generic azure-cloud-provider -n " +
azureDiskNamespace + " --from-file=cloud-config=/kind/azuredisk-azure.json"
azureDiskNamespace + " --from-file=cloud-config=/kind/azuredisk-azure.json"
_, err = commons.ExecuteCommand(n, c, 5, 3)
if err != nil {
return errors.Wrap(err, "failed to create azuredisk secret")
Expand Down
Loading

0 comments on commit 336682a

Please sign in to comment.