From c52231965cc09c1f191dcb0ec881456382432741 Mon Sep 17 00:00:00 2001 From: Rahul Roshan Kachchap Date: Wed, 29 Mar 2023 10:17:39 -0400 Subject: [PATCH] Remove psp-rolebinding from openstack-armada-app Removed the psp-rolebinding helm chart from being packaged as part of openstack-armada-app. Test Plan PASS: Build pkgs PASS: generate stx-openstack tarball PASS: system-application apply stx-openstack PASS: system-application remove stx-openstack PASS: application pkg doesn't consist psp-rolebinding helm chart Story: 2010590 Task: 47733 Signed-off-by: Rahul Roshan Kachchap Change-Id: Ifc8719b82ea0d3a72fea6595f9c8e2c1119ba94f --- .../k8sapp_openstack/common/constants.py | 2 - .../k8sapp_openstack/helm/psp_rolebinding.py | 32 --------------- .../k8sapp_openstack/setup.cfg | 3 +- .../debian/deb_folder/rules | 1 - .../debian/meta_data.yaml | 1 - .../manifests/ingress/helmrelease.yaml | 3 -- .../manifests/kustomization.yaml | 1 - .../nginx-ports-control/helmrelease.yaml | 3 -- .../psp-rolebinding/helmrelease.yaml | 37 ----------------- .../psp-rolebinding/kustomization.yaml | 20 --------- .../psp-rolebinding-static-overrides.yaml | 11 ----- .../psp-rolebinding-system-overrides.yaml | 0 stx-openstack-helm/debian/deb_folder/rules | 1 - stx-openstack-helm/debian/meta_data.yaml | 1 - .../manifests/manifest.yaml | 41 ------------------- 15 files changed, 1 insertion(+), 156 deletions(-) delete mode 100644 python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/psp_rolebinding.py delete mode 100644 stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/helmrelease.yaml delete mode 100644 stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/kustomization.yaml delete mode 100644 stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-static-overrides.yaml delete mode 100644 stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-system-overrides.yaml diff --git a/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/common/constants.py b/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/common/constants.py index 7b1ce977..92941dac 100644 --- a/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/common/constants.py +++ b/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/common/constants.py @@ -44,7 +44,6 @@ HELM_CHART_PLACEMENT = 'placement' HELM_CHART_RABBITMQ = 'rabbitmq' HELM_CHART_SWIFT = 'ceph-rgw' HELM_CHART_DCDBSYNC = 'dcdbsync' -HELM_CHART_PSP_ROLEBINDING = 'openstack-psp-rolebinding' # Helm Release constants FLUXCD_HELMRELEASE_AODH = 'aodh' @@ -76,7 +75,6 @@ FLUXCD_HELMRELEASE_PLACEMENT = 'placement' FLUXCD_HELMRELEASE_RABBITMQ = 'rabbitmq' FLUXCD_HELMRELEASE_SWIFT = 'ceph-rgw' FLUXCD_HELMRELEASE_DCDBSYNC = 'dcdbsync' -FLUXCD_HELMRELEASE_PSP_ROLEBINDING = 'openstack-psp-rolebinding' # Nova PCI Alias types and names # NOTE: Generic GPU and QAT definitions reside in sysinv/common/constants.py diff --git a/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/psp_rolebinding.py b/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/psp_rolebinding.py deleted file mode 100644 index 79eaa710..00000000 --- a/python3-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/psp_rolebinding.py +++ /dev/null @@ -1,32 +0,0 @@ -# -# Copyright (c) 2020 Wind River Systems, Inc. -# -# SPDX-License-Identifier: Apache-2.0 -# - -from sysinv.common import exception -from sysinv.helm import common - -from k8sapp_openstack.common import constants as app_constants -from k8sapp_openstack.helm import openstack - - -class PSPRolebindingHelm(openstack.BaseHelm): - """Class to encapsulate helm operations for the psp rolebinding chart""" - - CHART = app_constants.HELM_CHART_PSP_ROLEBINDING - HELM_RELEASE = app_constants.FLUXCD_HELMRELEASE_PSP_ROLEBINDING - SERVICE_NAME = 'psp-rolebinding' - - def get_overrides(self, namespace=None): - overrides = { - common.HELM_NS_OPENSTACK: {} - } - - if namespace in self.SUPPORTED_NAMESPACES: - return overrides[namespace] - elif namespace: - raise exception.InvalidHelmNamespace(chart=self.CHART, - namespace=namespace) - else: - return overrides diff --git a/python3-k8sapp-openstack/k8sapp_openstack/setup.cfg b/python3-k8sapp-openstack/k8sapp_openstack/setup.cfg index 5c443e7e..04bf031a 100644 --- a/python3-k8sapp-openstack/k8sapp_openstack/setup.cfg +++ b/python3-k8sapp-openstack/k8sapp_openstack/setup.cfg @@ -60,8 +60,7 @@ systemconfig.helm_plugins.openstack = 025_nginx-ports-control = k8sapp_openstack.helm.nginx_ports_control:NginxPortsControlHelm 026_fm-rest-api = k8sapp_openstack.helm.fm_rest_api:FmRestApiHelm 027_dcdbsync = k8sapp_openstack.helm.dcdbsync:DcdbsyncHelm - 028_openstack-psp-rolebinding = k8sapp_openstack.helm.psp_rolebinding:PSPRolebindingHelm - 029_pci-irq-affinity-agent = k8sapp_openstack.helm.pci_irq_affinity_agent:PciIrqAffinityAgentHelm + 028_pci-irq-affinity-agent = k8sapp_openstack.helm.pci_irq_affinity_agent:PciIrqAffinityAgentHelm systemconfig.fluxcd.kustomize_ops = openstack = k8sapp_openstack.kustomize.kustomize_openstack:OpenstackFluxCDKustomizeOperator diff --git a/stx-openstack-helm-fluxcd/debian/deb_folder/rules b/stx-openstack-helm-fluxcd/debian/deb_folder/rules index 173e98e9..6d66a9c0 100755 --- a/stx-openstack-helm-fluxcd/debian/deb_folder/rules +++ b/stx-openstack-helm-fluxcd/debian/deb_folder/rules @@ -26,7 +26,6 @@ override_dh_auto_build: cd helm-charts && make fm-rest-api cd helm-charts && make nginx-ports-control cd helm-charts && make dcdbsync - cd helm-charts && make psp-rolebinding # Terminate the helm chart server. pkill chartmuseum # Remove helm-toolkit. This will be packaged with openstack-helm-infra. diff --git a/stx-openstack-helm-fluxcd/debian/meta_data.yaml b/stx-openstack-helm-fluxcd/debian/meta_data.yaml index b8748fd9..5b9a8643 100644 --- a/stx-openstack-helm-fluxcd/debian/meta_data.yaml +++ b/stx-openstack-helm-fluxcd/debian/meta_data.yaml @@ -3,7 +3,6 @@ debname: stx-openstack-helm-fluxcd debver: 1.0-1 src_path: stx-openstack-helm-fluxcd src_files: - - ${MY_REPO}/stx/helm-charts/psp-rolebinding/psp-rolebinding/helm-charts - ${MY_REPO}/stx/helm-charts/fm-rest-api/fm-rest-api/helm-charts revision: dist: $STX_DIST diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/ingress/helmrelease.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/ingress/helmrelease.yaml index ec52f003..2f726b18 100644 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/ingress/helmrelease.yaml +++ b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/ingress/helmrelease.yaml @@ -29,9 +29,6 @@ spec: disableHooks: false upgrade: disableHooks: false - dependsOn: - - name: openstack-psp-rolebinding - namespace: openstack valuesFrom: - kind: Secret name: ingress-static-overrides diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/kustomization.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/kustomization.yaml index 70cf3a71..6e39d896 100644 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/kustomization.yaml +++ b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/kustomization.yaml @@ -10,7 +10,6 @@ kind: Kustomization namespace: openstack resources: - base - - psp-rolebinding - ingress - nginx-ports-control - mariadb diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/nginx-ports-control/helmrelease.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/nginx-ports-control/helmrelease.yaml index 6e68cb47..3c05d04e 100644 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/nginx-ports-control/helmrelease.yaml +++ b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/nginx-ports-control/helmrelease.yaml @@ -26,9 +26,6 @@ spec: enable: false upgrade: disableHooks: false - dependsOn: - - name: openstack-psp-rolebinding - namespace: openstack valuesFrom: - kind: Secret name: nginx-ports-control-static-overrides diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/helmrelease.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/helmrelease.yaml deleted file mode 100644 index f71e93ea..00000000 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/helmrelease.yaml +++ /dev/null @@ -1,37 +0,0 @@ -# -# Copyright (c) 2022 Wind River Systems, Inc. -# -# SPDX-License-Identifier: Apache-2.0 -# - ---- -apiVersion: "helm.toolkit.fluxcd.io/v2beta1" -kind: HelmRelease -metadata: - name: openstack-psp-rolebinding - labels: - chart_group: openstack-psp-rolebinding -spec: - releaseName: osh-openstack-psp-rolebinding - chart: - spec: - chart: psp-rolebinding - version: 0.1.0 - sourceRef: - kind: HelmRepository - name: starlingx - interval: 1m - timeout: 30m - test: - enable: false - upgrade: - disableHooks: false - dependsOn: [] - valuesFrom: - - kind: Secret - name: psp-rolebinding-static-overrides - valuesKey: psp-rolebinding-static-overrides.yaml - - kind: Secret - name: psp-rolebinding-system-overrides - valuesKey: psp-rolebinding-system-overrides.yaml -... diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/kustomization.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/kustomization.yaml deleted file mode 100644 index 510c13f5..00000000 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/kustomization.yaml +++ /dev/null @@ -1,20 +0,0 @@ -# -# Copyright (c) 2022 Wind River Systems, Inc. -# -# SPDX-License-Identifier: Apache-2.0 -# - ---- -namespace: openstack -resources: - - helmrelease.yaml -secretGenerator: - - name: psp-rolebinding-static-overrides - files: - - psp-rolebinding-static-overrides.yaml - - name: psp-rolebinding-system-overrides - files: - - psp-rolebinding-system-overrides.yaml -generatorOptions: - disableNameSuffixHash: true -... diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-static-overrides.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-static-overrides.yaml deleted file mode 100644 index 80ce1de3..00000000 --- a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-static-overrides.yaml +++ /dev/null @@ -1,11 +0,0 @@ -# -# Copyright (c) 2022 Wind River Systems, Inc. -# -# SPDX-License-Identifier: Apache-2.0 -# - ---- -release_group: osh-openstack-psp-rolebinding -rolebindingNamespace: openstack -serviceAccount: openstack -... diff --git a/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-system-overrides.yaml b/stx-openstack-helm-fluxcd/stx-openstack-helm-fluxcd/manifests/psp-rolebinding/psp-rolebinding-system-overrides.yaml deleted file mode 100644 index e69de29b..00000000 diff --git a/stx-openstack-helm/debian/deb_folder/rules b/stx-openstack-helm/debian/deb_folder/rules index 72430287..9bb1b7c8 100755 --- a/stx-openstack-helm/debian/deb_folder/rules +++ b/stx-openstack-helm/debian/deb_folder/rules @@ -26,7 +26,6 @@ override_dh_auto_build: cd helm-charts && make fm-rest-api cd helm-charts && make nginx-ports-control cd helm-charts && make dcdbsync - cd helm-charts && make psp-rolebinding # Terminate the helm chart server. pkill chartmuseum # Remove helm-toolkit. This will be packaged with openstack-helm-infra. diff --git a/stx-openstack-helm/debian/meta_data.yaml b/stx-openstack-helm/debian/meta_data.yaml index f33d6c6f..71128d0f 100644 --- a/stx-openstack-helm/debian/meta_data.yaml +++ b/stx-openstack-helm/debian/meta_data.yaml @@ -3,7 +3,6 @@ debname: stx-openstack-helm debver: 1.0-1 src_path: stx-openstack-helm src_files: - - ${MY_REPO}/stx/helm-charts/psp-rolebinding/psp-rolebinding/helm-charts - ${MY_REPO}/stx/helm-charts/fm-rest-api/fm-rest-api/helm-charts revision: dist: $STX_DIST diff --git a/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml b/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml index cc8d6aa9..5c837cf6 100644 --- a/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml +++ b/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml @@ -1,35 +1,5 @@ --- schema: armada/Chart/v1 -metadata: - schema: metadata/Document/v1 - name: openstack-psp-rolebinding -data: - chart_name: openstack-psp-rolebinding - dependencies: [] - namespace: openstack - release: openstack-psp-rolebinding - source: - location: http://172.17.0.1/helm_charts/starlingx/psp-rolebinding-0.1.0.tgz - subpath: psp-rolebinding - type: tar - reference: master - upgrade: - no_hooks: false - pre: - delete: - - labels: - release_group: osh-openstack-psp-rolebinding - type: job - wait: - labels: - release_group: osh-openstack-psp-rolebinding - resources: [] - timeout: 1800 - values: - rolebindingNamespace: openstack - serviceAccount: openstack ---- -schema: armada/Chart/v1 metadata: schema: metadata/Document/v1 name: helm-toolkit @@ -4204,16 +4174,6 @@ data: chart_group: - openstack-dcdbsync --- -schema: armada/ChartGroup/v1 -metadata: - schema: metadata/Document/v1 - name: openstack-psp-rolebinding -data: - description: "Deploy psp rolebinding" - sequenced: true - chart_group: - - openstack-psp-rolebinding ---- schema: armada/Manifest/v1 metadata: schema: metadata/Document/v1 @@ -4221,7 +4181,6 @@ metadata: data: release_prefix: osh chart_groups: - - openstack-psp-rolebinding - openstack-ingress - openstack-mariadb - openstack-memcached