Skip to content

Commit bc778cd

Browse files
committed
Address review comments / fix issues
1 parent fc176cb commit bc778cd

File tree

2 files changed

+19
-12
lines changed

2 files changed

+19
-12
lines changed

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,7 @@ generate-doctoc:
561561
TRACE=$(TRACE) ./hack/generate-doctoc.sh
562562

563563
.PHONY: generate-e2e-templates
564-
generate-e2e-templates: $(KUSTOMIZE) $(addprefix generate-e2e-templates-, v0.3 v0.4 v1.0 v1.5 main) ## Generate cluster templates for all versions
564+
generate-e2e-templates: $(KUSTOMIZE) $(addprefix generate-e2e-templates-, v0.3 v0.4 v1.0 v1.4 v1.5 main) ## Generate cluster templates for all versions
565565

566566
DOCKER_TEMPLATES := test/e2e/data/infrastructure-docker
567567
INMEMORY_TEMPLATES := test/e2e/data/infrastructure-inmemory

test/e2e/clusterctl_upgrade_test.go

+18-11
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ limitations under the License.
2020
package e2e
2121

2222
import (
23+
"runtime"
24+
2325
. "github.com/onsi/ginkgo/v2"
2426
"k8s.io/utils/pointer"
2527

@@ -32,6 +34,11 @@ var _ = Describe("When testing clusterctl upgrades (v0.3=>v1.5=>current)", func(
3234
// NOTE: The combination of v0.3=>v1.5=>current allows us to verify this without being forced to upgrade
3335
// the management cluster in the middle of the test as all 3 versions are ~ compatible with the same mgmt and workload Kubernetes versions.
3436
// Additionally, clusterctl v1.5 still allows the upgrade of management clusters from v1alpha3 (v1.6 doesn't).
37+
clusterctlDownloadURL03 := "https://github.com/kubernetes-sigs/cluster-api/releases/download/v0.3.25/clusterctl-{OS}-{ARCH}"
38+
if runtime.GOOS == "darwin" {
39+
// There is no arm64 binary for v0.3.x, so we'll use the amd64 one.
40+
clusterctlDownloadURL03 = "https://github.com/kubernetes-sigs/cluster-api/releases/download/v0.3.25/clusterctl-darwin-amd64"
41+
}
3542
ClusterctlUpgradeSpec(ctx, func() ClusterctlUpgradeSpecInput {
3643
return ClusterctlUpgradeSpecInput{
3744
E2EConfig: e2eConfig,
@@ -41,7 +48,7 @@ var _ = Describe("When testing clusterctl upgrades (v0.3=>v1.5=>current)", func(
4148
SkipCleanup: skipCleanup,
4249
InfrastructureProvider: pointer.String("docker"),
4350
// Configuration for the initial provider deployment.
44-
InitWithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v0.3.25/clusterctl-{OS}-{ARCH}",
51+
InitWithBinary: clusterctlDownloadURL03,
4552
// We have to pin the providers because with `InitWithProvidersContract` the test would
4653
// use the latest version for the contract.
4754
InitWithCoreProvider: "cluster-api:v0.3.25",
@@ -58,11 +65,11 @@ var _ = Describe("When testing clusterctl upgrades (v0.3=>v1.5=>current)", func(
5865
// Upgrade to v1.5.
5966
// Note: v1.5 is the highest version we can use as it's the last one
6067
// that is able to upgrade from a v1alpha3 management cluster.
61-
WithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.5.5/clusterctl-{OS}-{ARCH}",
62-
CoreProvider: "cluster-api:v1.5.5",
63-
BootstrapProviders: []string{"kubeadm:v1.5.5"},
64-
ControlPlaneProviders: []string{"kubeadm:v1.5.5"},
65-
InfrastructureProviders: []string{"docker:v1.5.5"},
68+
WithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.5.0/clusterctl-{OS}-{ARCH}",
69+
CoreProvider: "cluster-api:v1.5.0",
70+
BootstrapProviders: []string{"kubeadm:v1.5.0"},
71+
ControlPlaneProviders: []string{"kubeadm:v1.5.0"},
72+
InfrastructureProviders: []string{"docker:v1.5.0"},
6673
},
6774
{ // Upgrade to latest v1beta1.
6875
Contract: clusterv1.GroupVersion.Version,
@@ -115,11 +122,11 @@ var _ = Describe("When testing clusterctl upgrades (v0.4=>v1.5=>current)", func(
115122
// Upgrade to v1.5.
116123
// Note: v1.5 is a version we can use as it's
117124
// able to upgrade from a v1alpha4 management cluster (v1.6 would be able to as well)
118-
WithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.5.5/clusterctl-{OS}-{ARCH}",
119-
CoreProvider: "cluster-api:v1.5.5",
120-
BootstrapProviders: []string{"kubeadm:v1.5.5"},
121-
ControlPlaneProviders: []string{"kubeadm:v1.5.5"},
122-
InfrastructureProviders: []string{"docker:v1.5.5"},
125+
WithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.5.0/clusterctl-{OS}-{ARCH}",
126+
CoreProvider: "cluster-api:v1.5.0",
127+
BootstrapProviders: []string{"kubeadm:v1.5.0"},
128+
ControlPlaneProviders: []string{"kubeadm:v1.5.0"},
129+
InfrastructureProviders: []string{"docker:v1.5.0"},
123130
},
124131
{ // Upgrade to latest v1beta1.
125132
Contract: clusterv1.GroupVersion.Version,

0 commit comments

Comments
 (0)