Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
baf3527
Cancel instance refresh on any relevant change to ASG instead of bloc…
AndiDog Aug 28, 2025
4808f1c
ci: updates devbox.lock file
faiq Sep 10, 2025
da4e8cb
kep: adds nodedm proposal
faiq Sep 22, 2025
dbfb484
docs: refine wording around updates
faiq Sep 23, 2025
cc5e7e9
🐛 fix: use cluster tag key to list managed egress-only internet gateway
tthvo Jul 23, 2025
3cb4cdd
docs: fixes minor issues in nodeadm kep
faiq Sep 26, 2025
8607e3a
✨ Rosa roles config implementations (#5667)
serngawy Sep 30, 2025
c278953
ROSAMachinePool: support for capacity reservations (#5649)
mzazrivec Sep 30, 2025
36ef6ab
bump ginkgo timeout to 5h
damdo Oct 1, 2025
0050098
Merge pull request #5690 from damdo/bump-ginkgo-timeout
k8s-ci-robot Oct 1, 2025
f3c2166
✨ feat: Support setting EKS authentication mode (#5578)
joshfrench Oct 1, 2025
e0a7a0e
Update ROSA docs
andreadecorte Sep 23, 2025
77ef862
Merge pull request #5684 from tthvo/eigw-ipv6
k8s-ci-robot Oct 7, 2025
213faa0
Add ROSA-HCP AutoNode for karpenter auto scale (#5686)
serngawy Oct 7, 2025
afc356f
:seedling: Bump github.com/go-jose/go-jose/v4 from 4.0.2 to 4.0.5
dependabot[bot] Oct 7, 2025
516f342
✨ ROSANetwork: new CRD & reconciler to provision network infrastructu…
mzazrivec Oct 7, 2025
86e15f7
Merge pull request #5678 from faiq/faiq/add-nodeadm-kep
k8s-ci-robot Oct 7, 2025
4acbbff
Log desired AMI architecture and owner ID on errors
AndiDog Oct 8, 2025
4eade90
✨ Support EKS upgrade policy (#5471)
phuhung273 Oct 9, 2025
a499874
Update releasing.md
damdo Oct 10, 2025
d68b12b
Merge pull request #5704 from kubernetes-sigs/damdo-patch-1
k8s-ci-robot Oct 10, 2025
cd9d7ef
bump cloud build timeout to 2h
damdo Oct 10, 2025
46ee041
Merge pull request #5705 from damdo/cloudbuild-bump-timeout
k8s-ci-robot Oct 10, 2025
f742c3f
:seedling: Bump github/codeql-action from 3 to 4
dependabot[bot] Oct 13, 2025
1f5cdec
Merge pull request #5681 from andreadecorte/update_rosa_links
k8s-ci-robot Oct 14, 2025
de75624
Merge pull request #5688 from kubernetes-sigs/dependabot/go_modules/g…
k8s-ci-robot Oct 14, 2025
cc18666
Merge pull request #5703 from AndiDog/log-ami-arch
k8s-ci-robot Oct 14, 2025
c3838a1
Merge pull request #5707 from kubernetes-sigs/dependabot/github_actio…
k8s-ci-robot Oct 14, 2025
f2c01bf
feat: add node auto repair configuration for EKS managed node groups
afarbos Jul 31, 2025
15a2d14
Merge pull request #5543 from AndiDog/cancel-instance-refresh
k8s-ci-robot Oct 15, 2025
090a6d9
test: Add dedicated unit tests for getInstanceCPUOptionsRequest
fangge1212 Sep 22, 2025
6f867be
Merge pull request #5675 from fangge1212/add_unit_tests
k8s-ci-robot Oct 16, 2025
639a1a3
OIDC identity provider description matches field name
joshfrench Jul 2, 2025
05903a1
:seedling: Bump github.com/mikefarah/yq/v4
dependabot[bot] Oct 22, 2025
50fe899
Fix rosaNetwork set availabilityZones
serngawy Oct 23, 2025
886fe17
Add update permission for `AWSMachinePool` finalizers as needed by `O…
AndiDog Oct 21, 2025
ccd69ae
Merge pull request #5721 from serngawy/mainFixRosaNetwork
k8s-ci-robot Oct 23, 2025
b24bb91
add verify-go-directive check from core CAPI
damdo Oct 24, 2025
bcbecaa
Merge pull request #5710 from kubernetes-sigs/dependabot/go_modules/h…
k8s-ci-robot Oct 28, 2025
abcd42a
Merge pull request #5723 from damdo/add-verify-go-directive
k8s-ci-robot Oct 28, 2025
7ac683c
Allocate dedicated host when a dedicated host doesn't exist
rvanderp3 Oct 6, 2025
26bbb03
Merge pull request #5631 from openshift-splat-team/allocate-dedicated…
k8s-ci-robot Oct 30, 2025
1b94af9
Merge pull request #5664 from faiq/faiq/update-devbox
k8s-ci-robot Nov 5, 2025
853f4bf
Fix delete rosa-hcp
serngawy Nov 5, 2025
bb846f0
Merge pull request #5730 from serngawy/fixDelete
k8s-ci-robot Nov 9, 2025
e2a0554
:seedling: Bump golangci/golangci-lint-action from 8.0.0 to 9.0.0
dependabot[bot] Nov 10, 2025
8ff7054
Merge pull request #5722 from AndiDog/blockownerdeletion-fix
k8s-ci-robot Nov 11, 2025
24c32f4
:seedling: Bump sigs.k8s.io/kustomize/kustomize/v5
dependabot[bot] Nov 12, 2025
617e4b5
Merge pull request #5579 from joshfrench/fix-oidc-docstring
k8s-ci-robot Nov 13, 2025
9274e10
Merge pull request #5734 from kubernetes-sigs/dependabot/github_actio…
k8s-ci-robot Nov 13, 2025
8216ef0
Merge pull request #5735 from kubernetes-sigs/dependabot/go_modules/h…
k8s-ci-robot Nov 13, 2025
f9f767e
Drop unused conversion functions
chrischdi Nov 14, 2025
805e912
Merge pull request #5740 from chrischdi/pr-drop-unused-conversion-fun…
k8s-ci-robot Nov 14, 2025
e6811a2
hack/tools: use mainstream conversion-gen
damdo Nov 14, 2025
4938d7b
rerun: make generate
damdo Nov 14, 2025
42b4f94
Merge pull request #5739 from damdo/switch-to-mainstream-conversion-gen
k8s-ci-robot Nov 14, 2025
694e191
e2e: fix panic when dumping CloudTrail logs
chrischdi Nov 17, 2025
c0ef9f4
Merge pull request #5747 from chrischdi/pr-fix-panic-e2e
k8s-ci-robot Nov 17, 2025
1e6f612
Merge pull request #5604 from afarbos/af/EKSNodeRepair
k8s-ci-robot Nov 19, 2025
532baf8
:seedling: Bump golang.org/x/crypto from 0.43.0 to 0.45.0 in /hack/tools
dependabot[bot] Nov 20, 2025
5b67a67
Merge pull request #5755 from kubernetes-sigs/dependabot/go_modules/h…
k8s-ci-robot Nov 20, 2025
26c3586
🌱 Bump CAPI to v1.11 and k8s to v1.33 (#5720)
clebs Nov 21, 2025
d475146
Remove invalid kustomizeconfig from config/webhook
mdbooth Nov 21, 2025
89f1eab
Only try to delete AWSMachine bootstrap data for non-machine pool mac…
AndiDog Nov 21, 2025
31e29fe
Fix lifecycle hooks being updated constantly, consider changes to `Ro…
AndiDog Nov 14, 2025
9ea47d0
✨ feat: Implement autoscaling from zero by auto-populating AWSMachine…
LiangquanLi930 Nov 21, 2025
f6c53bb
Merge pull request #5759 from openshift-cloud-team/remove-invalid-kus…
k8s-ci-robot Nov 21, 2025
0e1ecd7
Deflake ROSA test
AndiDog Nov 21, 2025
ed98c60
Merge pull request #5761 from AndiDog/machine-pool-machine-deletion
k8s-ci-robot Nov 21, 2025
a809fcb
Merge pull request #5762 from AndiDog/avoid-lifecyclehook-constant-up…
k8s-ci-robot Nov 21, 2025
04a4f62
Merge pull request #5763 from AndiDog/deflake-rosa-test
k8s-ci-robot Nov 21, 2025
02e8126
write_files: nil is invalid cloud-config
joshfrench Nov 24, 2025
aae18b7
Bump sigs.k8s.io/cluster-api/test to release-1.11 commit for e2e fixes
chrischdi Nov 20, 2025
6301be1
fix linting error
chrischdi Nov 25, 2025
3b302dd
Merge pull request #5758 from chrischdi/pr-e2e-timeout-fix
k8s-ci-robot Nov 26, 2025
32e7d74
fix(controllers): add watches to resolve AWSMachineTemplate e2e race …
LiangquanLi930 Nov 24, 2025
cf0fed0
Merge pull request #5765 from LiangquanLi930/fix-e2e
k8s-ci-robot Nov 27, 2025
8b060c8
e2e: adjust templates to use AWSClusterRoleIdentities per Cluster
chrischdi Nov 27, 2025
45c7a2e
Merge pull request #5773 from chrischdi/pr-clusterroleidentity-per-test
k8s-ci-robot Nov 28, 2025
2a454ad
autoscaling: try to gather the version information from MachineSets a…
chrischdi Nov 27, 2025
c8e04c8
Merge pull request #5774 from chrischdi/pr-autoscale-ms-e2e-refactor
k8s-ci-robot Nov 28, 2025
4b1dd04
Merge pull request #5768 from joshfrench/skip-empty-files
k8s-ci-robot Nov 28, 2025
a203e17
Fix constant re-applying of tags if `.metadata.annotations` is nil (#…
AndiDog Nov 27, 2025
cef5795
chore: update owners and aliases
richardcase Dec 1, 2025
7f4c07d
fix: e2e: validate inputData during log postprocessing to avoid panic
damdo Dec 1, 2025
ac96235
Merge pull request #5780 from richardcase/maintainer_changes_dec_25
k8s-ci-robot Dec 1, 2025
17a9871
github actions: bump to go 1.24
damdo Dec 1, 2025
175074f
Merge pull request #5782 from damdo/bump-github-action-go-1.24
k8s-ci-robot Dec 1, 2025
beb4dca
metadata: prepare main for next release
chrischdi Dec 2, 2025
ba5489a
Merge pull request #5785 from chrischdi/pr-prepare-2-11
k8s-ci-robot Dec 3, 2025
fe9c0fe
docs: update releasing.md with steps post-release
chrischdi Dec 2, 2025
ea774f5
Merge pull request #5784 from chrischdi/pr-capa-releasing
k8s-ci-robot Dec 3, 2025
6460ac1
Merge pull request #5775 from AndiDog/avoid-constant-tagging
k8s-ci-robot Dec 9, 2025
60a1df2
Merge pull request #5779 from damdo/fix-e2e-postprocesslog-panic
k8s-ci-robot Dec 9, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ jobs:

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v3
uses: github/codeql-action/autobuild@v4

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
uses: github/codeql-action/analyze@v4
2 changes: 1 addition & 1 deletion .github/workflows/pr-golangci-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
with:
go-version: ${{ steps.vars.outputs.go_version }}
- name: golangci-lint
uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # tag=v8.0.0
uses: golangci/golangci-lint-action@0a35821d5c230e903fcfe077583637dea1b27b47 # tag=v9.0.0
with:
version: v2.1.0
working-directory: ${{matrix.working-directory}}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: '1.23'
go-version: '1.24'
- name: Set version info
run: |
echo "VERSION=${GITHUB_REF_NAME}" >> $GITHUB_ENV
Expand Down
41 changes: 24 additions & 17 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,6 @@ linters:
alias: runtimeserializer
- pkg: k8s.io/apimachinery/pkg/runtime/serializer/yaml
alias: yamlserializer
- pkg: sigs.k8s.io/cluster-api/api/v1beta1
alias: clusterv1
- pkg: sigs.k8s.io/cluster-api/util/defaulting
alias: utildefaulting
- pkg: sigs.k8s.io/controller-runtime
Expand Down Expand Up @@ -169,8 +167,14 @@ linters:
alias: crclient
- pkg: k8s.io/apimachinery/pkg/types
alias: apimachinerytypes
- pkg: sigs.k8s.io/cluster-api/exp/api/v1beta1
alias: expclusterv1
- pkg: "sigs.k8s.io/cluster-api/api/core/v1beta2"
alias: clusterv1
- pkg: "sigs.k8s.io/cluster-api/api/core/v1beta1"
alias: clusterv1beta1
- pkg: "sigs.k8s.io/cluster-api/util/deprecated/v1beta1/patch"
alias: v1beta1patch
- pkg: "sigs.k8s.io/cluster-api/util/deprecated/v1beta1/conditions"
alias: v1beta1conditions
no-unaliased: false
nolintlint:
require-specific: true
Expand Down Expand Up @@ -212,16 +216,16 @@ linters:
# - errcheck
# text: Error return value of `outputPrinter.Print` is not checked
- linters:
- gosec
text: 'G103: Use of unsafe calls should be audited'
- gosec
text: "G103: Use of unsafe calls should be audited"
path: .*(api|types|test)\/.*\/.*conversion.*\.go$
- linters:
- staticcheck
text: 'QF1008: could remove embedded field .*'
text: "QF1008: could remove embedded field .*"
# TODO: change to use time.Time.Equal
- linters:
- staticcheck
text: 'QF1009: probably want to use time.Time.Equal instead'
text: "QF1009: probably want to use time.Time.Equal instead"
- linters:
- revive
# Ignoring stylistic checks for generated code
Expand All @@ -233,13 +237,13 @@ linters:
# Ignoring stylistic checks for generated code
path: .*(api|types)\/.*\/.*conversion.*\.go$
# By convention, receiver names in a method should reflect their identity.
text: 'receiver-naming: receiver name (.+) should be consistent with previous receiver name (.+)'
text: "receiver-naming: receiver name (.+) should be consistent with previous receiver name (.+)"
- linters:
- revive
# Ignoring stylistic checks for generated code
path: .*(api|types|test)\/.*\/.*conversion.*\.go$
# Checking if an error is nil to just after return the error or nil is redundant
text: 'if-return: redundant if ...; err != nil check, just return error instead'
text: "if-return: redundant if ...; err != nil check, just return error instead"
- linters:
- revive
text: 'exported: exported method .*\.(Reconcile|SetupWithManager|SetupWebhookWithManager) should have comment or be unexported'
Expand Down Expand Up @@ -268,7 +272,7 @@ linters:
text: Error return value of (.+) is not checked
- linters:
- gosec
text: 'G108: Profiling endpoint is automatically exposed on /debug/pprof'
text: "G108: Profiling endpoint is automatically exposed on /debug/pprof"
- linters:
- godot
path: (.*)/(v1beta1|v1beta2)/(.*)types.go
Expand All @@ -282,17 +286,17 @@ linters:
- linters:
- revive
path: .*/defaults.go
text: 'var-naming: don''t use underscores in Go names; func (.+) should be (.+)'
text: "var-naming: don't use underscores in Go names; func (.+) should be (.+)"
- linters:
- revive
path: .*/.*(mock|gc_).*/.+\.go
text: 'var-naming: don''t use an underscore in package name'
text: "var-naming: don't use an underscore in package name"
- linters:
- revive
# Ignoring stylistic checks for generated code
path: .*(api|types|test)\/.*\/.*conversion.*\.go$
# This rule warns when initialism, variable or package naming conventions are not followed.
text: 'var-naming: don''t use underscores in Go names'
text: "var-naming: don't use underscores in Go names"
- linters:
- unparam
text: always receives
Expand All @@ -309,20 +313,23 @@ linters:
text: cyclomatic complexity
- linters:
- gocritic
text: 'appendAssign: append result not assigned to the same slice'
text: "appendAssign: append result not assigned to the same slice"
- path: (.+)\.go$
text: (Expect directory permissions to be 0750 or less|Expect file permissions to be 0600 or less)
- path: (.+)\.go$
text: 'exported: (func|type) name will be used as (.+) by other packages, and that stutters; consider calling this (.+)'
text: "exported: (func|type) name will be used as (.+) by other packages, and that stutters; consider calling this (.+)"
- path: (.+)\.go$
text: (G104|G107|G404|G505|ST1000)
- path: (.+)\.go$
text: 'G108: Profiling endpoint is automatically exposed on /debug/pprof'
text: "G108: Profiling endpoint is automatically exposed on /debug/pprof"
- path: (.+)\.go$
text: net/http.Get must not be called
- linters:
- goconst
path: (.+)_test\.go
- linters:
- staticcheck
text: 'SA1019: "sigs.k8s.io/cluster-api/(.*)" is deprecated: This package is deprecated and is going to be removed when support for v1beta1 will be dropped.'
paths:
- third_party$
- builtin$
Expand Down
23 changes: 15 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ include $(ROOT_DIR_RELATIVE)/common.mk

# Go
GO_VERSION ?=1.24.7
GO_DIRECTIVE_VERSION ?= 1.24.0
GO_CONTAINER_IMAGE ?= golang:$(GO_VERSION)

# Directories.
Expand Down Expand Up @@ -170,7 +171,7 @@ ifeq ($(findstring \[PR-Blocking\],$(GINKGO_FOCUS)),\[PR-Blocking\])
endif

override E2E_ARGS += -artifacts-folder="$(ARTIFACTS)" --data-folder="$(E2E_DATA_DIR)" -use-existing-cluster=$(USE_EXISTING_CLUSTER)
override GINKGO_ARGS += -v --trace --timeout=4h --output-dir="$(ARTIFACTS)" --junit-report="junit.e2e_suite.xml"
override GINKGO_ARGS += -v --trace --timeout=5h --output-dir="$(ARTIFACTS)" --junit-report="junit.e2e_suite.xml"

ifdef GINKGO_SKIP
override GINKGO_ARGS += -skip "$(GINKGO_SKIP)"
Expand Down Expand Up @@ -204,7 +205,7 @@ endif
.PHONY: defaulters
defaulters: $(DEFAULTER_GEN) ## Generate all Go types
$(DEFAULTER_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--v=0 \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
--output-file=zz_generated.defaults.go \
Expand Down Expand Up @@ -262,36 +263,36 @@ generate-go-apis: ## Alias for .build/generate-go-apis
$(MAKE) defaulters

$(CONVERSION_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--output-file=zz_generated.conversion.go \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
./api/v1beta1 \
./cmd/clusterawsadm/api/bootstrap/v1alpha1

$(CONVERSION_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--output-file=zz_generated.conversion.go \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
./$(EXP_DIR)/api/v1beta1

$(CONVERSION_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--output-file=zz_generated.conversion.go \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
./bootstrap/eks/api/v1beta1

$(CONVERSION_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--output-file=zz_generated.conversion.go \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
./controlplane/eks/api/v1beta1

$(CONVERSION_GEN) \
--extra-peer-dirs=sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/v1beta1 \
--extra-peer-dirs=sigs.k8s.io/cluster-api/api/core/v1beta2 \
--output-file=zz_generated.conversion.go \
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt \
./controlplane/rosa/api/v1beta2
Expand Down Expand Up @@ -329,7 +330,7 @@ modules: ## Runs go mod to ensure proper vendoring.
cd $(TOOLS_DIR); go mod tidy

.PHONY: verify ## Verify ties together the rest of the verification targets into one target
verify: verify-boilerplate verify-modules verify-gen verify-conversions verify-shellcheck verify-book-links release-manifests
verify: verify-boilerplate verify-modules verify-gen verify-conversions verify-shellcheck verify-book-links release-manifests verify-go-directive

.PHONY: verify-boilerplate
verify-boilerplate: ## Verify boilerplate
Expand Down Expand Up @@ -367,6 +368,12 @@ verify-gen: generate ## Verify generated files
verify-container-images: ## Verify container images
TRACE=$(TRACE) ./hack/verify-container-images.sh

.PHONY: verify-go-directive
verify-go-directive:
# use the core Cluster API script directly to verify the go directive matches the desired one.
# ref: https://github.com/kubernetes-sigs/cluster-api/blob/v1.10.7/hack/verify-go-directive.sh
curl --retry 3 -fsL https://raw.githubusercontent.com/kubernetes-sigs/cluster-api/refs/tags/v1.10.7/hack/verify-go-directive.sh | bash -s -- -g $(GO_DIRECTIVE_VERSION)

.PHONY: apidiff
apidiff: APIDIFF_OLD_COMMIT ?= $(shell git rev-parse origin/main)
apidiff: $(GO_APIDIFF) ## Check for API differences
Expand Down
1 change: 1 addition & 0 deletions OWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ reviewers:
- cluster-api-aws-reviewers

emeritus_approvers:
- Ankitasw
- AverageMarcus
- chuckha
- detiber
Expand Down
5 changes: 1 addition & 4 deletions OWNERS_ALIASES
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,10 @@ aliases:
- richardcase
cluster-api-aws-maintainers:
- richardcase
- Ankitasw
- dlipovetsky
- nrb
- AndiDog
- damdo
cluster-api-aws-reviewers:
- luthermonson
- cnmcavoy
- faiq
- fiunchinho
- damdo
6 changes: 6 additions & 0 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,9 @@ resources:
- group: infrastructure
version: v1beta2
kind: AWSManagedCluster
- group: infrastructure
kind: ROSARoleConfig
version: v1beta2
- group: infrastructure
kind: ROSANetwork
version: v1beta2
3 changes: 3 additions & 0 deletions api/v1beta1/awscluster_conversion.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ func (src *AWSCluster) ConvertTo(dstRaw conversion.Hub) error {
dst.Status.Bastion.HostID = restored.Status.Bastion.HostID
dst.Status.Bastion.CapacityReservationPreference = restored.Status.Bastion.CapacityReservationPreference
dst.Status.Bastion.CPUOptions = restored.Status.Bastion.CPUOptions
if restored.Status.Bastion.DynamicHostAllocation != nil {
dst.Status.Bastion.DynamicHostAllocation = restored.Status.Bastion.DynamicHostAllocation
}
}
dst.Spec.Partition = restored.Spec.Partition

Expand Down
20 changes: 10 additions & 10 deletions api/v1beta1/awscluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ package v1beta1
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
clusterv1beta1 "sigs.k8s.io/cluster-api/api/core/v1beta1"
)

const (
Expand All @@ -45,7 +45,7 @@ type AWSClusterSpec struct {

// ControlPlaneEndpoint represents the endpoint used to communicate with the control plane.
// +optional
ControlPlaneEndpoint clusterv1.APIEndpoint `json:"controlPlaneEndpoint"`
ControlPlaneEndpoint clusterv1beta1.APIEndpoint `json:"controlPlaneEndpoint"`

// AdditionalTags is an optional set of tags to add to AWS resources managed by the AWS provider, in addition to the
// ones added by default.
Expand Down Expand Up @@ -200,11 +200,11 @@ type AWSLoadBalancerSpec struct {
// AWSClusterStatus defines the observed state of AWSCluster.
type AWSClusterStatus struct {
// +kubebuilder:default=false
Ready bool `json:"ready"`
Network NetworkStatus `json:"networkStatus,omitempty"`
FailureDomains clusterv1.FailureDomains `json:"failureDomains,omitempty"`
Bastion *Instance `json:"bastion,omitempty"`
Conditions clusterv1.Conditions `json:"conditions,omitempty"`
Ready bool `json:"ready"`
Network NetworkStatus `json:"networkStatus,omitempty"`
FailureDomains clusterv1beta1.FailureDomains `json:"failureDomains,omitempty"`
Bastion *Instance `json:"bastion,omitempty"`
Conditions clusterv1beta1.Conditions `json:"conditions,omitempty"`
}

// S3Bucket defines a supporting S3 bucket for the cluster, currently can be optionally used for Ignition.
Expand Down Expand Up @@ -254,12 +254,12 @@ type AWSClusterList struct {
}

// GetConditions returns the observations of the operational state of the AWSCluster resource.
func (r *AWSCluster) GetConditions() clusterv1.Conditions {
func (r *AWSCluster) GetConditions() clusterv1beta1.Conditions {
return r.Status.Conditions
}

// SetConditions sets the underlying service state of the AWSCluster to the predescribed clusterv1.Conditions.
func (r *AWSCluster) SetConditions(conditions clusterv1.Conditions) {
// SetConditions sets the underlying service state of the AWSCluster to the predescribed clusterv1beta1.Conditions.
func (r *AWSCluster) SetConditions(conditions clusterv1beta1.Conditions) {
r.Status.Conditions = conditions
}

Expand Down
6 changes: 3 additions & 3 deletions api/v1beta1/awsclustertemplate_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ package v1beta1
import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
clusterv1beta1 "sigs.k8s.io/cluster-api/api/core/v1beta1"
)

// AWSClusterTemplateSpec defines the desired state of AWSClusterTemplate.
Expand Down Expand Up @@ -58,6 +58,6 @@ type AWSClusterTemplateResource struct {
// Standard object's metadata.
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
// +optional
ObjectMeta clusterv1.ObjectMeta `json:"metadata,omitempty"`
Spec AWSClusterSpec `json:"spec"`
ObjectMeta clusterv1beta1.ObjectMeta `json:"metadata,omitempty"`
Spec AWSClusterSpec `json:"spec"`
}
11 changes: 11 additions & 0 deletions api/v1beta1/awsmachine_conversion.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ func (src *AWSMachine) ConvertTo(dstRaw conversion.Hub) error {
dst.Spec.CapacityReservationPreference = restored.Spec.CapacityReservationPreference
dst.Spec.NetworkInterfaceType = restored.Spec.NetworkInterfaceType
dst.Spec.CPUOptions = restored.Spec.CPUOptions
if restored.Spec.DynamicHostAllocation != nil {
dst.Spec.DynamicHostAllocation = restored.Spec.DynamicHostAllocation
}
if restored.Spec.ElasticIPPool != nil {
if dst.Spec.ElasticIPPool == nil {
dst.Spec.ElasticIPPool = &infrav1.ElasticIPPool{}
Expand All @@ -61,6 +64,7 @@ func (src *AWSMachine) ConvertTo(dstRaw conversion.Hub) error {
}
}

dst.Status.DedicatedHost = restored.Status.DedicatedHost
return nil
}

Expand Down Expand Up @@ -117,6 +121,9 @@ func (r *AWSMachineTemplate) ConvertTo(dstRaw conversion.Hub) error {
dst.Spec.Template.Spec.CapacityReservationPreference = restored.Spec.Template.Spec.CapacityReservationPreference
dst.Spec.Template.Spec.NetworkInterfaceType = restored.Spec.Template.Spec.NetworkInterfaceType
dst.Spec.Template.Spec.CPUOptions = restored.Spec.Template.Spec.CPUOptions
if restored.Spec.Template.Spec.DynamicHostAllocation != nil {
dst.Spec.Template.Spec.DynamicHostAllocation = restored.Spec.Template.Spec.DynamicHostAllocation
}
if restored.Spec.Template.Spec.ElasticIPPool != nil {
if dst.Spec.Template.Spec.ElasticIPPool == nil {
dst.Spec.Template.Spec.ElasticIPPool = &infrav1.ElasticIPPool{}
Expand All @@ -129,6 +136,10 @@ func (r *AWSMachineTemplate) ConvertTo(dstRaw conversion.Hub) error {
}
}

// Restore Status fields that don't exist in v1beta1.
dst.Status.NodeInfo = restored.Status.NodeInfo
dst.Status.Conditions = restored.Status.Conditions

return nil
}

Expand Down
Loading