Commit Graph

239 Commits

Author SHA1 Message Date
Zhiwei Yin
b6c2a848e8 fix gc controller not handle empty cluster (#812)
Some checks failed
Post / coverage (push) Failing after 26m18s
Post / images (amd64) (push) Failing after 7m14s
Post / images (arm64) (push) Failing after 6m40s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m2s
Close stale issues and PRs / stale (push) Successful in 28s
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2025-01-23 01:41:27 +00:00
Zhiwei Yin
f03b3f75eb change replicas of klusterlet operator to 1 (#813)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m0s
Post / coverage (push) Failing after 26m22s
Post / images (amd64) (push) Failing after 6m56s
Post / images (arm64) (push) Failing after 6m55s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2025-01-20 03:45:09 +00:00
jaswalkiranavtar
f62242d047 Assume prerequisite role on hub if initailize with aws-irsa (#807)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m28s
Post / coverage (push) Failing after 26m43s
Post / images (amd64) (push) Failing after 6m50s
Post / images (arm64) (push) Failing after 6m49s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 35s
* Adding managedcluster identity creator role arn

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

* Addressing review comments

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

---------

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>
Co-authored-by: Amrutha <amrutha.hari12@gmail.com>
2025-01-17 16:37:47 +00:00
Jian Qiu
d323b60253 Change the component name to klusterlet-agent (#809)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-17 10:34:11 +00:00
Jian Qiu
54a99fe880 Requeue importer when secret is not found (#808)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-17 10:25:57 +00:00
Jian Qiu
34275ef1ea Add bootstrapSA flags for importer (#803)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m14s
Post / coverage (push) Failing after 27m13s
Post / images (amd64) (push) Failing after 6m57s
Post / images (arm64) (push) Failing after 6m49s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 25s
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-16 08:55:31 +00:00
Jian Qiu
19fb9243ca Check capi status if it is provisioned (#801)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-16 02:44:15 +00:00
Zhiwei Yin
a44b44e2db rename bootstrap sa and rbac (#802)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m11s
Post / coverage (push) Failing after 27m28s
Post / images (amd64) (push) Failing after 6m52s
Post / images (arm64) (push) Failing after 6m37s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 21s
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2025-01-16 01:13:30 +00:00
Zhiwei Yin
5df279f2d1 set empty nodeselect to nil (#799)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m10s
Post / coverage (push) Failing after 26m1s
Post / images (amd64) (push) Failing after 6m59s
Post / images (arm64) (push) Failing after 6m48s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2025-01-14 10:04:51 +00:00
jaswalkiranavtar
7261646cb0 Adding Guidewire team members to registration owners (#796)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m4s
Post / coverage (push) Failing after 26m34s
Post / images (amd64) (push) Failing after 7m3s
Post / images (arm64) (push) Failing after 6m50s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
* Adding Guidewire team members to registration owners

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

* shrinking the list to remove members who have not made contributions yet

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

---------

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>
2025-01-13 01:55:20 +00:00
Jian Qiu
11896ccda1 Fix the issue that ownerref is not set with ignorefields (#794)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 45s
Post / images (amd64) (push) Failing after 5m38s
Post / images (arm64) (push) Failing after 5m35s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Post / coverage (push) Failing after 26m35s
Close stale issues and PRs / stale (push) Successful in 25s
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-10 03:19:59 +00:00
jaswalkiranavtar
0acf030cdb Completing aws registration on spoke (#788)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 40s
Post / images (amd64) (push) Failing after 5m45s
Post / images (arm64) (push) Failing after 5m45s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Post / coverage (push) Failing after 26m38s
Close stale issues and PRs / stale (push) Successful in 6s
* Completing aws registration on spoke

Signed-off-by: suvaanshkumar <suvaanshkumar@gmail.com>

* adding new function to overcome gci errors on slices

Signed-off-by: suvaanshkumar <suvaanshkumar@gmail.com>

* Refactoring array contains function

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

---------

Signed-off-by: suvaanshkumar <suvaanshkumar@gmail.com>
Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>
Co-authored-by: suvaanshkumar <suvaanshkumar@gmail.com>
2025-01-09 19:07:43 +00:00
Jian Qiu
2397c4e911 Add cache for applyUnstructured (#769)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 59s
Post / images (amd64) (push) Failing after 14m29s
Post / coverage (push) Failing after 26m17s
Post / images (arm64) (push) Failing after 6m52s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 39s
This could reduce the number of calls to the spoke cluster

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-08 15:46:53 +00:00
Yang Le
9af100f427 🐛 fix work agent performance issue (#785)
Some checks failed
Post / images (amd64) (push) Failing after 5m31s
Post / images (arm64) (push) Failing after 5m31s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Post / coverage (push) Failing after 27m33s
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m11s
Signed-off-by: Yang Le <yangle@redhat.com>
2025-01-08 10:01:24 +00:00
Jian Qiu
037aa3ccfa Ignore field should not be honored when creating the resource (#784)
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 12m44s
Post / images (amd64) (push) Failing after 8m35s
Post / coverage (push) Failing after 26m36s
Post / images (arm64) (push) Failing after 9m10s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 30s
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2025-01-03 06:09:48 +00:00
xuezhao
8737358919 Agents stop update managedcluster status when clock is out of sync. (#770)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2024-12-23 01:34:33 +00:00
Jian Qiu
b568123849 Start import in registration by feature gate. (#775)
* Update clustermanager operator to support capi

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Update operator to start importer

Signed-off-by: Jian Qiu <jqiu@redhat.com>

---------

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-12-20 01:12:10 +00:00
Jian Zhu
3f9b8867eb Add a configmap to handle the proxy ca bundle (#772)
* Add a configmap to handle the proxy ca bundle

Signed-off-by: zhujian <jiazhu@redhat.com>

* Use contextual logger

Signed-off-by: zhujian <jiazhu@redhat.com>

---------

Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-19 03:29:03 +00:00
Jian Qiu
25ea10bcbf Add importer into registration (#753)
* Add importer into registraiton

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Add unit tests

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Add integration test

Signed-off-by: Jian Qiu <jqiu@redhat.com>

---------

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-12-16 13:59:55 +00:00
Jian Zhu
3493630ad2 Support configuring proxy for addons (#760)
* Support configuring proxy for addons

Signed-off-by: zhujian <jiazhu@redhat.com>

* Add tests for addon proxy setting

Signed-off-by: zhujian <jiazhu@redhat.com>

* Add e2e test for signer namespace

Signed-off-by: zhujian <jiazhu@redhat.com>

---------

Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-16 08:01:34 +00:00
jaswalkiranavtar
b170f3a41e Cluster decorator interface (#759)
* Add cluster decorator interface in register

And refactor creating to controller to call decorators

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Add aws annotations to ManagedCluster using Decorator

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

* Addressing review comments

Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>

---------

Signed-off-by: Jian Qiu <jqiu@redhat.com>
Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>
Co-authored-by: Jian Qiu <jqiu@redhat.com>
2024-12-11 15:59:43 +00:00
Jian Zhu
ddc5024596 Allow Custom Signer signingCA to Specify Namespace in AddOnTemplate (#747)
* Allow Custom Signer signingCA to Specify Namespace in AddOnTemplate

Signed-off-by: zhujian <jiazhu@redhat.com>

* Add e2e test for signer namespace

Signed-off-by: zhujian <jiazhu@redhat.com>

---------

Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-10 09:16:26 +00:00
Jian Qiu
0897da69da Implement ignoreFields in server side apply (#726)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-12-10 02:56:55 +00:00
Suvaansh
9eb8131bea Create registration option by driver type after bootstrap (#744)
Signed-off-by: suvaanshkumar <suvaanshkumar@gmail.com>
Co-authored-by: Jian Qiu <jqiu@redhat.com>
2024-12-06 02:05:23 +00:00
jaswalkiranavtar
a138a547f5 Adding second group for aws auth flow (#735)
Signed-off-by: Gaurav Jaswal <jaswalkiranavtar@gmail.com>
2024-12-05 06:36:18 +00:00
Jian Zhu
80935909c0 🐛 Only bind the agent role for the addon group (#721)
* Only bind the agent role for the addon group

Signed-off-by: zhujian <jiazhu@redhat.com>

* Update addon rolebinding

Signed-off-by: zhujian <jiazhu@redhat.com>

* Tigger registration reconcile after start

Signed-off-by: zhujian <jiazhu@redhat.com>

* Address code review comments

Signed-off-by: zhujian <jiazhu@redhat.com>

---------

Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-03 02:18:34 +00:00
Jian Zhu
41a01b1da0 Change kubecofnig secret creation time to non pointer (#731)
Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-02 05:26:18 +00:00
Jian Zhu
6e367a2b26 🌱 Move index func from addon framework to ocm (#728)
* Move index func from addon framework to ocm

Signed-off-by: zhujian <jiazhu@redhat.com>

* Address code review comments

Signed-off-by: zhujian <jiazhu@redhat.com>

---------

Signed-off-by: zhujian <jiazhu@redhat.com>
2024-12-02 01:40:46 +00:00
Qing Hao
ed367fd739 enable leader election of klusterlet-agent on single node managed clusters (#727)
Signed-off-by: Qing Hao <qhao@redhat.com>
2024-11-29 08:13:48 +00:00
jaswalkiranavtar
93db6de4a1 Starting aws registration by spoke by assuming IAM role on startup and adding annotations to ManagedCluster CR (#714)
* Starting aws registration by spoke by assuming IAM role on startup and adding annotations to ManagedCluster CR

Signed-off-by: Erica Jin <132393634+EricaJ6@users.noreply.github.com>

* Adding integration tests for aws registration

Signed-off-by: Erica Jin <132393634+EricaJ6@users.noreply.github.com>

* Adding more integration tests

Signed-off-by: Erica Jin <132393634+EricaJ6@users.noreply.github.com>

* Addressing review comments

Signed-off-by: Erica Jin <132393634+EricaJ6@users.noreply.github.com>

---------

Signed-off-by: Erica Jin <132393634+EricaJ6@users.noreply.github.com>
2024-11-26 17:34:53 +00:00
Jian Qiu
627a16ddfc Fix: Should use metadata name queue key func for addon informer (#722)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-11-25 07:50:56 +00:00
Wei Liu
9ab61dfae8 update sdk-go to fix unstable test (#715)
Signed-off-by: Wei Liu <liuweixa@redhat.com>
2024-11-25 04:24:44 +00:00
Yang Le
2f9dcc2ea5 🌱 support CA file in the bootstrap hub kubeconfig (#710)
Signed-off-by: Yang Le <yangle@redhat.com>
2024-11-21 09:06:35 +00:00
Zhiwei Yin
fa3a30b36e support wildcard in manifestConfigs (#703)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2024-11-21 06:56:46 +00:00
xuezhao
68eb264e56 Revert "enable leader election of klusterlet-agent on single node managed clusters (#695)" (#708)
This reverts commit 8544ff1e29.

Signed-off-by: xuezhaojun <zxue@redhat.com>
2024-11-20 03:45:47 +00:00
Qing Hao
8544ff1e29 enable leader election of klusterlet-agent on single node managed clusters (#695)
Signed-off-by: Qing Hao <qhao@redhat.com>
2024-11-15 02:47:00 +00:00
Rokibul Hasan
369f3fb6ff Update api dependency and remove unnecessary featureGate enabling part (#687)
Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>
2024-11-14 07:12:14 +00:00
Jian Zhu
109bd9456e Record the external kubeconfig creation timestamp (#700)
Signed-off-by: zhujian <jiazhu@redhat.com>
2024-11-14 01:35:31 +00:00
Suvaansh
67b4f1a354 Add AWS IAM support (#677)
* Adding AWS IAM authentication support

Signed-off-by: EmilyL <70486866+dtclxy64@users.noreply.github.com>

* Remove the bootstrapKubeconfigEventHandler field that's no longer used from the NewSpokeAgentConfig function based on code review comments.

Signed-off-by: Suvaansh <34331549+suvaanshkumar@users.noreply.github.com>

* Add a comment on what the IsEksArnWellFormed function does and an example EKS ARN.

Signed-off-by: Suvaansh <34331549+suvaanshkumar@users.noreply.github.com>
Signed-off-by: Emily Li <70486866+dtclxy64@users.noreply.github.com>

---------

Signed-off-by: EmilyL <70486866+dtclxy64@users.noreply.github.com>
Signed-off-by: Suvaansh <34331549+suvaanshkumar@users.noreply.github.com>
Signed-off-by: Emily Li <70486866+dtclxy64@users.noreply.github.com>
Co-authored-by: EmilyL <70486866+dtclxy64@users.noreply.github.com>
2024-11-13 01:43:28 +00:00
Jian Qiu
5911a7e920 🐛 Fix manifestwork and appliedmanifestwork unsync issue (#636)
* Fix manifestwork and appliedmanifestwork unsync issue

merge the two controller as reconcilers for one controller

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Add an integration test

Signed-off-by: Jian Qiu <jqiu@redhat.com>

---------

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-11-11 01:59:35 +00:00
xuezhao
7664585c22 Fix: reduce cluster rbac when accpet to false. (#675)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2024-11-04 02:02:25 +00:00
Rokibul Hasan
e24937ff75 Fix issue with printing <nil> for error messages (#681)
Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>
2024-10-31 09:02:13 +00:00
Wei Liu
d26db93494 Add auto approve anno for accepted cluster (#680)
Signed-off-by: Wei Liu <liuweixa@redhat.com>
2024-10-31 02:52:23 +00:00
Jian Qiu
fa98535693 🐛 Use context cancel func to trigger reselect (#658)
* Use context cancel func to trigger reselect

Signed-off-by: Jian Qiu <jqiu@redhat.com>

* Add test to improve coverage

Signed-off-by: Jian Qiu <jqiu@redhat.com>

---------

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-10-29 02:06:13 +00:00
Rokibul Hasan
a0370e2e5d Remove ManagedClusterSet webhook registration part (#678)
Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>
2024-10-28 13:43:44 +00:00
xuezhao
26f9e74ac9 Rename and relocate cluster related roles files. (#674)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2024-10-28 01:56:29 +00:00
Rokibul Hasan
e9245d46d7 🐛 Fix duplicate deployment names in klusterlet-agent availability message (#671)
* Fix duplicate deployment names in klusterlet-agent availability message

Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>

* Update

Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>

---------

Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>
2024-10-28 01:53:47 +00:00
Rokibul Hasan
20a7b83c5c Register ManifestWorkReplicaSet webhook when feature is enabled (#673)
Signed-off-by: Rokibul Hasan <mdrokibulhasan@appscode.com>
2024-10-28 01:51:01 +00:00
Jian Qiu
900248f214 Return false when accept return error (#622)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-10-21 10:51:00 +00:00
Yang Le
9a47edcae0 🐛 handle the unknown status of the previously accepted cluster (#656)
Signed-off-by: Yang Le <yangle@redhat.com>
2024-10-21 02:33:13 +00:00