From da9f28cefa7e7afb262ab0b0b7f4193b9f98c7fc Mon Sep 17 00:00:00 2001 From: jinyuanliu Date: Tue, 2 Mar 2021 23:53:53 +0800 Subject: [PATCH] Update rbac api version for keystone 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: If37ec26443feb5328d49e6b3c419305832bdae9e --- keystone/Chart.yaml | 2 +- keystone/templates/cron-job-credential-rotate.yaml | 4 ++-- keystone/templates/cron-job-fernet-rotate.yaml | 4 ++-- keystone/templates/job-credential-setup.yaml | 4 ++-- keystone/templates/job-fernet-setup.yaml | 4 ++-- releasenotes/notes/keystone.yaml | 2 ++ 6 files changed, 11 insertions(+), 9 deletions(-) diff --git a/keystone/Chart.yaml b/keystone/Chart.yaml index 8997b310e3..7cc042a619 100644 --- a/keystone/Chart.yaml +++ b/keystone/Chart.yaml @@ -14,7 +14,7 @@ apiVersion: v1 appVersion: v1.0.0 description: OpenStack-Helm Keystone name: keystone -version: 0.1.9 +version: 0.1.10 home: https://docs.openstack.org/keystone/latest/ icon: https://www.openstack.org/themes/openstack/images/project-mascots/Keystone/OpenStack_Project_Keystone_vertical.png sources: diff --git a/keystone/templates/cron-job-credential-rotate.yaml b/keystone/templates/cron-job-credential-rotate.yaml index 532290b8f9..fd26b230c0 100644 --- a/keystone/templates/cron-job-credential-rotate.yaml +++ b/keystone/templates/cron-job-credential-rotate.yaml @@ -21,7 +21,7 @@ limitations under the License. {{- $serviceAccountName := "keystone-credential-rotate" }} {{ tuple $envAll "credential_rotate" $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 }} @@ -36,7 +36,7 @@ rules: - create - update --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/keystone/templates/cron-job-fernet-rotate.yaml b/keystone/templates/cron-job-fernet-rotate.yaml index 1090dc7365..8f4f4f9a58 100644 --- a/keystone/templates/cron-job-fernet-rotate.yaml +++ b/keystone/templates/cron-job-fernet-rotate.yaml @@ -22,7 +22,7 @@ limitations under the License. {{- $serviceAccountName := "keystone-fernet-rotate" }} {{ tuple $envAll "fernet_rotate" $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 }} @@ -37,7 +37,7 @@ rules: - create - update --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/keystone/templates/job-credential-setup.yaml b/keystone/templates/job-credential-setup.yaml index 11e8ce6055..1543d8a6bf 100644 --- a/keystone/templates/job-credential-setup.yaml +++ b/keystone/templates/job-credential-setup.yaml @@ -21,7 +21,7 @@ limitations under the License. {{- $serviceAccountName := "keystone-credential-setup" }} {{ tuple $envAll "credential_setup" $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 }} @@ -36,7 +36,7 @@ rules: - create - update --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/keystone/templates/job-fernet-setup.yaml b/keystone/templates/job-fernet-setup.yaml index c488414f8a..6a39daf3e7 100644 --- a/keystone/templates/job-fernet-setup.yaml +++ b/keystone/templates/job-fernet-setup.yaml @@ -22,7 +22,7 @@ limitations under the License. {{- $serviceAccountName := "keystone-fernet-setup" }} {{ tuple $envAll "fernet_setup" $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 }} @@ -37,7 +37,7 @@ rules: - create - update --- -apiVersion: rbac.authorization.k8s.io/v1beta1 +apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: {{ $serviceAccountName }} diff --git a/releasenotes/notes/keystone.yaml b/releasenotes/notes/keystone.yaml index 1ff8f786f2..74863ca015 100644 --- a/releasenotes/notes/keystone.yaml +++ b/releasenotes/notes/keystone.yaml @@ -10,3 +10,5 @@ keystone: - 0.1.7 Move rabbit-init to dynamic dependency - 0.1.8 Change Issuer to ClusterIssuer - 0.1.9 Add helm.sh/hook related annotations + - 0.1.10 Update RBAC apiVersion from /v1beta1 to /v1 +...