Commit Graph

91 Commits

Author SHA1 Message Date
DangPeng Liu
f020c8a48d clusterset v1beta1 migration (#315)
Signed-off-by: ldpliu <daliu@redhat.com>
2023-02-12 23:00:58 -05:00
Jian Zhu
9d7ee1149a regenerate and load hosted secrets when ca changes (#316)
Signed-off-by: zhujian <jiazhu@redhat.com>
2023-02-10 01:00:12 -05:00
Jian Qiu
c3baabeec2 use crd manager to update and clean crds (#297)
* use crd manager to update clean crds

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

* Update tests

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

* Rebase crd manager

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

* build client builder to make code clearer

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

* Add ut for crdmanager

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

* Compare crd spec when update

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

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-12-15 20:40:46 -05:00
xuezhaojun
5459ac86e7 Add test case for hubConfigSecretMissing case. (#307)
Signed-off-by: xuezhaojun <zxue@redhat.com>

Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-12-06 02:13:56 -05:00
Jian Zhu
1ab08bd6d7 Make work agent feature gate configurable (#303)
* Make work agent feature gate configurable

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

* Merge registration and work feature gate conditions

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

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-11-27 20:55:43 -05:00
Jian Qiu
e12657c501 Refactor klusterlet (#306)
Signed-off-by: Jian Qiu <jqiu@redhat.com>

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-11-23 08:28:05 -05:00
Jian Qiu
94f17dedd1 Refactor clustermanager controller (#305)
* Refactor clustermanager controller

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

* Refactor cond update

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

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-11-23 04:30:49 -05:00
DangPeng Liu
7c8d71e194 use controller-runtime webhook (#293)
Signed-off-by: ldpliu <daliu@redhat.com>

Signed-off-by: ldpliu <daliu@redhat.com>
2022-11-17 06:45:25 +00:00
xuezhaojun
fbeb0e224d Upgrade ginkgo to v2. (#301)
Signed-off-by: xuezhaojun <zxue@redhat.com>

Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-11-16 01:20:54 +00:00
Jian Qiu
514fff1469 upgrade appliedmanifestwork API (#298)
Signed-off-by: Jian Qiu <jqiu@redhat.com>

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-11-07 08:27:26 -05:00
Jian Qiu
fbbb5d9f48 Fix token path in hosted mode (#284)
Signed-off-by: Jian Qiu <jqiu@redhat.com>

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-10-18 02:54:08 -04:00
Jian Zhu
432fac3616 Remove install mode detached (#282)
Signed-off-by: zhujian <jiazhu@redhat.com>

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-10-17 05:43:34 -04:00
DangPeng Liu
6bf6df2f2c add conversion webhook (#279)
Signed-off-by: ldpliu <daliu@redhat.com>

Signed-off-by: ldpliu <daliu@redhat.com>
2022-10-14 00:19:30 -04:00
Jian Zhu
0944f98904 Make work webhook feature gate configurable (#276)
Signed-off-by: zhujian <jiazhu@redhat.com>

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-09-23 08:47:08 +02:00
Wei Liu
0f5141c5fc update add-on configuration apis (#272)
Signed-off-by: Wei Liu <liuweixa@redhat.com>

Signed-off-by: Wei Liu <liuweixa@redhat.com>
2022-09-09 07:52:55 +02:00
Jian Zhu
59b5e56fd3 Refactor to split two controllers to handle klusterlet deployment and cleanup (#269)
Signed-off-by: zhujian <jiazhu@redhat.com>

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-08-18 03:31:13 +00:00
Zhiwei Yin
b14e41788a upgrade go lib to the latest version and bump csv to 0.9.0 (#265)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2022-07-26 02:42:46 +02:00
Bowen Zhu
79d280ad8a Add HubApiServerHostAlias for registration-agent and work-agent (#258)
Signed-off-by: Bowen Zhu <Promacanthus@gmail.com>

Add HubApiServerHostAlias for registration-agent and work-agent
2022-07-11 04:17:01 +00:00
Jian Qiu
a7dd402db8 Use token request to sync sa (#259)
* Use token request to sync sa

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

* Upgrade kind

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-07-06 06:09:10 +00:00
Jian Zhu
4b1061dda0 add permisson for registration agent for running addon in hosted mode (#256)
Signed-off-by: zhujian <jiazhu@redhat.com>
2022-07-05 08:20:14 +00:00
Qing Hao
803bfb3748 split work permissions (#252)
* split work permissions

Signed-off-by: haoqing0110 <qhao@redhat.com>

* add more comments

Signed-off-by: haoqing0110 <qhao@redhat.com>
2022-06-28 02:31:44 +00:00
Qing Hao
54452f060a split registration permissions (#250)
* split registration permissions

Signed-off-by: haoqing0110 <qhao@redhat.com>

* more comments

Signed-off-by: haoqing0110 <qhao@redhat.com>
2022-06-27 08:13:31 +00:00
ivanscai
3401c8e4bd support hubRegistrationFeatureGates and spokeRegistrationFeatureGates (#230)
* support RegistrationFeatureGates in ClusterManager and Klusterlet

Signed-off-by: ivan-cai <caijing.cai@alibaba-inc.com>

* update to use DefaultHubRegistrationFeatureGates&DefaultSpokeRegistrationFeatureGates in api repo to check registration variable if valid

Signed-off-by: ivan-cai <caijing.cai@alibaba-inc.com>

* enable addonmanagement and defaultClusterset feature if RegistrationConfiguration is nil

Signed-off-by: ivan-cai <caijing.cai@alibaba-inc.com>

* fix some errors in unit test

Signed-off-by: ivan-cai <caijing.cai@alibaba-inc.com>

* add RegistrationFeatureGates to registration webhook

Signed-off-by: ivan-cai <caijing.cai@alibaba-inc.com>

Co-authored-by: caijing.cai <caijing.cai@alibaba-inc.com>
2022-06-22 06:47:06 +00:00
Lei P
4f8ca8c6e3 Update file name to reflect the change in Makefile (#245)
Signed-off-by: Lei Pan <leipan@ibm.com>
2022-05-13 06:57:33 +00:00
xuezhaojun
11efeb18b5 Add goci lint. (#243)
* Add goci lint.

Signed-off-by: xuezhaojun <zxue@redhat.com>

* handle errs and remove unused.

Signed-off-by: xuezhaojun <zxue@redhat.com>

* fix fail and remove unused code.

Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-05-10 02:50:42 -04:00
Yang Le
c93f5cefd2 add missing permission on kube v1.11.0 (#234)
Signed-off-by: Yang Le <yangle@redhat.com>
2022-04-08 06:48:17 -04:00
Yang Le
ebf48bc123 support Klusterlet.Spec.Namespace in hosted mode (#227)
Signed-off-by: Yang Le <yangle@redhat.com>
2022-03-30 05:20:13 -04:00
xuezhaojun
7aa41cda65 Add hosted mode in klusterlet (#220)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-03-15 05:03:53 -04:00
xuezhaojun
84e12c9197 Change to hosted mode in cluster-manager (#219)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-03-15 01:11:52 -04:00
Jian Qiu
db866a5891 Upgrade api and library (#217)
* Upgrade api and library

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

* update permission for operator

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-03-14 22:23:53 -04:00
Jian Zhu
78f2de10b1 Add finalizer before creating clients (#216)
Signed-off-by: zhujian <jiazhu@redhat.com>
2022-03-14 10:32:29 -04:00
Zhiwei Yin
a67f11c21e only set work-agent replica 0 when hub-kubeconfig-secret is missing (#213)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2022-03-10 05:40:06 -05:00
DangPeng Liu
bb76f8cb7c trigger new build (#212)
Signed-off-by: ldpliu <daliu@redhat.com>
2022-03-08 22:54:07 -05:00
DangPeng Liu
55bc274d79 enable feature gate for registration webhook (#210)
Signed-off-by: ldpliu <daliu@redhat.com>
2022-03-03 03:47:22 -05:00
xuezhaojun
00fcdcd30a add detached mode to cluster-manager controller (#190)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-02-24 07:57:40 -05:00
Jian Zhu
71fcc78d5f Make the klusterlet install mode optional (#207)
* Make the klusterlet install mode optional

- Update cluster manager and klusterlet api
- Make the klusterlet install mode optional
- Add e2e test to ensure the backward compatibility

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

* Update vendor for the open cluster management api

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-02-23 22:15:29 -05:00
Jian Qiu
61c96873b3 Refactor on connecton check in klusterlet (#202)
1. Update observerved generation
2. Code update to clear the logic

Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-02-14 02:50:36 -05:00
Qing Hao
2c2316fafa update placement and placementdecision to v1beta1 (#198)
* update placement and placementdecision to v1beta1

Signed-off-by: haoqing0110 <qhao@redhat.com>

* add placement and placementdecision StorageVersionMigration

Signed-off-by: haoqing0110 <qhao@redhat.com>
2022-01-27 09:06:51 -05:00
Jian Qiu
156867faf5 Disable leader election when replica is 1 (#193)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2022-01-18 04:50:05 -05:00
Zhiwei Yin
6814943229 scale up the work agent deployment after the hub-kuebeconfig-secret is created (#184)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2022-01-18 01:36:05 -05:00
Qing Hao
50f1e8410a add addonplacementscore (#187)
* add addonplacementscore

Signed-off-by: haoqing0110 <qhao@redhat.com>

* remove addonplacementscore on spoke

Signed-off-by: haoqing0110 <qhao@redhat.com>
2022-01-11 10:55:09 +01:00
Min Kim
00c6bb1d89 adding an option that skips placeholder hub secret (#185)
Signed-off-by: yue9944882 <291271447@qq.com>
2022-01-10 14:34:50 +01:00
Zhiwei Yin
f7ff0557df get the namespace of klusterlet from helper (#181)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2022-01-10 07:42:50 +01:00
xuezhaojun
7b1f044875 support customize cluster manager namespace (#179)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2022-01-06 13:50:37 +01:00
Jian Zhu
dcf93fa3b9 support deploy klusterlet outside of managed cluster (#172)
* support deploy klusterlet outside of managed cluster

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

* create manged cluster kubeconfig by sa syncer

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

* fix CI issues

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

* add unit test

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

* separate the manifests and operations for klusterlet operator

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

* add unit test

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

* add integration test

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

* add e2e test

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

* address code review comments

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

* distinguish the RBAC resource names of managed cluster and management cluster

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

* ensure the klusterlet namespace early

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

* update csv

Signed-off-by: zhujian <jiazhu@redhat.com>
2022-01-04 08:24:14 +01:00
xuezhaojun
c90d98e6da update api dependency (#177)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2021-12-16 16:01:51 +01:00
Zhiwei Yin
4ee4d15544 update relatedResources in clusterManager and kluterler (#173)
Signed-off-by: Zhiwei Yin <zyin@redhat.com>
2021-12-01 10:43:58 +01:00
Wei Liu
15b74555fb reduce the sar request when hub kubeconfig is valid (#160)
Signed-off-by: liuwei <liuweixa@redhat.com>
2021-11-10 08:13:39 +01:00
xuezhaojun
9c5338b282 fix resource pressure on hub when too many managed cluster registrate at once (#152)
Signed-off-by: xuezhaojun <zxue@redhat.com>
2021-09-29 06:17:54 -04:00
kim-fitness
d56e34f53d fix issue #150 and add related integration/unit test cases
Signed-off-by: kim-fitness <jianjin@cn.ibm.com>
2021-09-26 15:40:45 +08:00