Merge pull request #1547 from AllenZMC/improve_test

helm: add cluster proxy rbac for admin when deploy Karmada control plane
This commit is contained in:
karmada-bot 2022-03-31 17:21:03 +08:00 committed by GitHub
commit ffa9227cc8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 163 additions and 137 deletions

View File

@ -102,7 +102,7 @@ $ helm install karmada-scheduler-estimator -n karmada-system ./charts
```
## Configuration
| Name | Description | Value |
| ------------------------- | ----------------------------------------------- | ----- |
|------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `installMode` | InstallMode "host", "agent" and "component" are provided, "host" means install karmada in the control-cluster, "agent" means install agent client in the member cluster, "component" means install selected components in the control-cluster | `"host"` |
| `clusterDomain` | Default cluster domain for karmada | `"cluster.local"` |
| `components` | Selected components list, selectable values: "schedulerEstimator" | `[]` |

View File

@ -0,0 +1,26 @@
{{- $name := include "karmada.name" . -}}
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: {{ $name }}-cluster-proxy-admin
rules:
- apiGroups:
- 'cluster.karmada.io'
resources:
- clusters/proxy
verbs:
- '*'
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: {{ $name }}-cluster-proxy-admin
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ $name }}-cluster-proxy-admin
subjects:
- kind: User
name: "system:admin"