From 566e1cb6698ec69efc14e881b24034eee833db22 Mon Sep 17 00:00:00 2001 From: jinyuanliu Date: Sat, 27 Feb 2021 11:42:39 +0800 Subject: [PATCH] Update rbac api version for cinder When using a helm3 to deploy , it fails. Helm3 no more support rbac.authorization.k8s.io/v1beta1 , but v1 can support helm2 and helm3. Change-Id: Ie4e1c79c2b2513318d1b7d6a13712921a6c2a6cb --- cinder/Chart.yaml | 2 +- cinder/templates/job-backup-storage-init.yaml | 4 ++-- cinder/templates/job-clean.yaml | 4 ++-- cinder/templates/job-storage-init.yaml | 4 ++-- releasenotes/notes/cinder.yaml | 1 + 5 files changed, 8 insertions(+), 7 deletions(-) diff --git a/cinder/Chart.yaml b/cinder/Chart.yaml index 2eed59f66d..23274680fe 100644 --- a/cinder/Chart.yaml +++ b/cinder/Chart.yaml @@ -14,7 +14,7 @@ apiVersion: v1 appVersion: v1.0.0 description: OpenStack-Helm Cinder name: cinder -version: 0.1.10 +version: 0.1.11 home: https://docs.openstack.org/cinder/latest/ icon: https://www.openstack.org/themes/openstack/images/project-mascots/Cinder/OpenStack_Project_Cinder_vertical.png sources: diff --git a/cinder/templates/job-backup-storage-init.yaml b/cinder/templates/job-backup-storage-init.yaml index f53fd1b8a6..a310aebbc6 100644 --- a/cinder/templates/job-backup-storage-init.yaml +++ b/cinder/templates/job-backup-storage-init.yaml @@ -18,7 +18,7 @@ limitations under the License. {{- $serviceAccountName := "cinder-backup-storage-init" }} {{ tuple $envAll "backup_storage_init" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }} --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: {{ $serviceAccountName }} @@ -33,7 +33,7 @@ rules: - update - patch --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/cinder/templates/job-clean.yaml b/cinder/templates/job-clean.yaml index f1310c662e..a5e118b31c 100755 --- a/cinder/templates/job-clean.yaml +++ b/cinder/templates/job-clean.yaml @@ -19,7 +19,7 @@ limitations under the License. {{- $serviceAccountName := print "cinder-clean" }} {{ tuple $envAll "clean" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }} --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: {{ $serviceAccountName }} @@ -32,7 +32,7 @@ rules: - get - delete --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/cinder/templates/job-storage-init.yaml b/cinder/templates/job-storage-init.yaml index 75880209b0..810a428fd8 100755 --- a/cinder/templates/job-storage-init.yaml +++ b/cinder/templates/job-storage-init.yaml @@ -20,7 +20,7 @@ limitations under the License. {{- $serviceAccountName := "cinder-storage-init" }} {{ tuple $envAll "storage_init" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }} --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: {{ $serviceAccountName }} @@ -35,7 +35,7 @@ rules: - update - patch --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/releasenotes/notes/cinder.yaml b/releasenotes/notes/cinder.yaml index 0fd10595ec..332e6d5688 100644 --- a/releasenotes/notes/cinder.yaml +++ b/releasenotes/notes/cinder.yaml @@ -11,3 +11,4 @@ cinder: - 0.1.8 Revert - Change Issuer to ClusterIssuer - 0.1.9 Use HostToContainer mount propagation - 0.1.10 Change Issuer to ClusterIssuer + - 0.1.11 Update RBAC apiVersion from /v1beta1 to /v1