Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.

Commit 826abc7

Browse files
committed
breaking: Update to CAPI 1.5
- remove support for packet-ccm - reduce tag length (capp instead of cluster-api-provider-packet) - use quay.io repo by default - fix lint errors - bump to capi 1.5.4 - upgrade metal-go to v0.29.0 - bump go version of Dockerfile to 1.20.11 - fix return types for new CR version - add new logging calls more like upstream has - update rbac for packet-controller - better logging of unimplemented webhooks - add new clusterproxy methods to wrappedclusterproxy in e2e testing - bump e2e config capi versions - Update e2e yaml files to only test v1beta1 - revert e2e ci config to standard version numbers - remove e2e clusterctl upgrade test as we dropped v1alpha3 support Signed-off-by: Chris Privitere <[email protected]>
1 parent 82c9317 commit 826abc7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+785
-4294
lines changed

.github/workflows/ci.yaml

Lines changed: 256 additions & 312 deletions
Large diffs are not rendered by default.

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ dist
4545
.tiltbuild/
4646

4747
# E2E test templates
48-
test/e2e/data/v1alpha3/cluster-template*.yaml
4948
test/e2e/data/v1beta1/cluster-template*.yaml
5049

5150
#VS Code

.golangci.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -205,13 +205,6 @@ issues:
205205
# changes in PRs and avoid nitpicking.
206206
exclude-use-default: false
207207
exclude-rules:
208-
- path: api/v1alpha3
209-
linters:
210-
- revive
211-
- gosec
212-
- stylecheck
213-
# Specific exclude rules for deprecated fields that are still part of the codebase. These
214-
# should be removed as the referenced deprecated item is removed from the project.
215208
- linters:
216209
- staticcheck
217210
text: "SA1019: (noderefutil.*|parsed.*) is deprecated"

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# limitations under the License.
1616

1717
# Build the manager binary
18-
ARG GOVER=1.20.10
18+
ARG GOVER=1.20.11
1919
FROM golang:${GOVER} as builder
2020

2121
WORKDIR /workspace

Makefile

Lines changed: 7 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -69,12 +69,12 @@ endif
6969
## Binaries.
7070

7171
# Sync to controller-tools version in https://github.com/kubernetes-sigs/cluster-api/blob/v{VERSION}/hack/tools/go.mod
72-
CONTROLLER_GEN_VER := v0.11.4
72+
CONTROLLER_GEN_VER := v0.12.0
7373
CONTROLLER_GEN_BIN := controller-gen
7474
CONTROLLER_GEN := $(TOOLS_BIN_DIR)/$(CONTROLLER_GEN_BIN)-$(CONTROLLER_GEN_VER)
7575

76-
# Sync to k8s.io/* verisons in https://github.com/kubernetes-sigs/cluster-api/blob/v{VERSION}/go.mod
77-
CONVERSION_GEN_VER := v0.26.1
76+
# Sync to k8s.io/* versions in https://github.com/kubernetes-sigs/cluster-api/blob/v{VERSION}/go.mod
77+
CONVERSION_GEN_VER := v0.27.8
7878
CONVERSION_GEN_BIN := conversion-gen
7979
CONVERSION_GEN := $(TOOLS_BIN_DIR)/$(CONVERSION_GEN_BIN)-$(CONVERSION_GEN_VER)
8080

@@ -84,7 +84,7 @@ ENVSUBST_BIN := envsubst
8484
ENVSUBST := $(TOOLS_BIN_DIR)/$(ENVSUBST_BIN)
8585

8686
# Bump as necessary/desired to latest that supports our version of go at https://github.com/golangci/golangci-lint/releases
87-
GOLANGCI_LINT_VER := v1.51.1
87+
GOLANGCI_LINT_VER := v1.53.3
8888
GOLANGCI_LINT_BIN := golangci-lint
8989
GOLANGCI_LINT := $(TOOLS_BIN_DIR)/$(GOLANGCI_LINT_BIN)-$(GOLANGCI_LINT_VER)
9090

@@ -95,15 +95,15 @@ KUSTOMIZE_BIN := kustomize
9595
KUSTOMIZE := $(TOOLS_BIN_DIR)/$(KUSTOMIZE_BIN)-$(KUSTOMIZE_VER)
9696

9797
# Sync to github.com/onsi/ginkgo verison in https://github.com/kubernetes-sigs/cluster-api/blob/v{VERSION}/go.mod
98-
GINKGO_VER := v2.9.2
98+
GINKGO_VER := v2.11.0
9999
GINKGO_BIN := ginkgo
100100
GINKGO := $(abspath $(TOOLS_BIN_DIR)/$(GINKGO_BIN)-$(GINKGO_VER))
101101
GINKGO_PKG := github.com/onsi/ginkgo/v2/ginkgo
102102

103103
TIMEOUT := $(shell command -v timeout || command -v gtimeout)
104104

105105
# Define Docker related variables. Releases should modify and double check these vars.
106-
REGISTRY ?= ghcr.io/kubernetes-sigs
106+
REGISTRY ?= quay.io/equinix-oss
107107
export IMAGE_NAME ?= cluster-api-provider-packet
108108
export CONTROLLER_IMG ?= $(REGISTRY)/$(IMAGE_NAME)
109109
export TAG ?= dev
@@ -219,12 +219,7 @@ test-e2e-ci:
219219
TEST_TEMPLATES_TARGET_DIR ?= $(REPO_ROOT)/test/e2e/data
220220

221221
.PHONY: e2e-test-templates
222-
e2e-test-templates: $(KUSTOMIZE) e2e-test-templates-v1alpha3 e2e-test-templates-v1beta1 ## Generate cluster templates for all versions
223-
224-
e2e-test-templates-v1alpha3: $(KUSTOMIZE) ## Generate cluster templates for v1alpha3
225-
mkdir -p $(TEST_TEMPLATES_TARGET_DIR)/v1alpha3/
226-
$(KUSTOMIZE) build $(REPO_ROOT)/test/e2e/data/v1alpha3/cluster-template-packet-ccm --load-restrictor LoadRestrictionsNone > $(TEST_TEMPLATES_TARGET_DIR)/v1alpha3/cluster-template-packet-ccm.yaml
227-
$(KUSTOMIZE) build $(REPO_ROOT)/test/e2e/data/v1alpha3/cluster-template-cpem --load-restrictor LoadRestrictionsNone > $(TEST_TEMPLATES_TARGET_DIR)/v1alpha3/cluster-template-cpem.yaml
222+
e2e-test-templates: $(KUSTOMIZE) e2e-test-templates-v1beta1 ## Generate cluster templates for all versions
228223

229224
e2e-test-templates-v1beta1: $(KUSTOMIZE) ## Generate cluster templates for v1beta1
230225
mkdir -p $(TEST_TEMPLATES_TARGET_DIR)/v1beta1/
@@ -297,12 +292,6 @@ generate-go: $(CONTROLLER_GEN) $(CONVERSION_GEN) ## Runs Go related generate tar
297292
$(CONTROLLER_GEN) \
298293
paths=./api/... \
299294
object:headerFile=./hack/boilerplate.go.txt
300-
$(CONVERSION_GEN) \
301-
--input-dirs=./api/v1alpha3 \
302-
--build-tag=ignore_autogenerated_core_v1alpha3 \
303-
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1alpha3 \
304-
--output-file-base=zz_generated.conversion \
305-
--go-header-file=./hack/boilerplate.go.txt $(GEN_OUTPUT_BASE)
306295
go generate ./...
307296

308297
.PHONY: generate-manifests

api/v1alpha3/doc.go

Lines changed: 0 additions & 19 deletions
This file was deleted.

api/v1alpha3/groupversion_info.go

Lines changed: 0 additions & 39 deletions
This file was deleted.

api/v1alpha3/packetcluster_conversion.go

Lines changed: 0 additions & 77 deletions
This file was deleted.

api/v1alpha3/packetcluster_types.go

Lines changed: 0 additions & 84 deletions
This file was deleted.

0 commit comments

Comments
 (0)