diff --git a/centos_iso_image.inc b/centos_iso_image.inc index f501763..b6438ac 100644 --- a/centos_iso_image.inc +++ b/centos_iso_image.inc @@ -1,2 +1 @@ stx-snmp-helm -stx-snmp-helm-armada diff --git a/stx-snmp-helm/centos/stx-snmp-helm.spec b/stx-snmp-helm/centos/stx-snmp-helm.spec index e09beb7..29bb819 100644 --- a/stx-snmp-helm/centos/stx-snmp-helm.spec +++ b/stx-snmp-helm/centos/stx-snmp-helm.spec @@ -2,8 +2,6 @@ %global app_name snmp %global helm_repo stx-platform -%global armada_folder /usr/lib/armada - # Install location %global app_folder /usr/local/share/applications/helm @@ -31,14 +29,6 @@ BuildRequires: python-k8sapp-snmp-wheels %description StarlingX SNMP Helm Charts -%package armada -Summary: StarlingX SNMP Armada Helm Charts -Group: base -License: Apache-2.0 - -%description armada -StarlingX SNMP Armada Helm Charts - %prep %setup -n helm-charts-snmp-0-1-0-1.0.0 @@ -52,18 +42,15 @@ cd - # Create a chart tarball compliant with sysinv kube-app.py %define app_staging %{_builddir}/staging -%define app_tarball_armada %{app_name}-armada-%{version}-%{tis_patch_ver}.tgz %define app_tarball_fluxcd %{app_name}-%{version}-%{tis_patch_ver}.tgz # Setup staging mkdir -p %{app_staging} cp files/metadata.yaml %{app_staging} -cp manifests/*.yaml %{app_staging} mkdir -p %{app_staging}/charts cp helm-charts/*.tgz %{app_staging}/charts # Populate metadata -cd %{app_staging} sed -i 's/@APP_NAME@/%{app_name}/g' %{app_staging}/metadata.yaml sed -i 's/@APP_VERSION@/%{version}-%{tis_patch_ver}/g' %{app_staging}/metadata.yaml sed -i 's/@HELM_REPO@/%{helm_repo}/g' %{app_staging}/metadata.yaml @@ -72,17 +59,6 @@ sed -i 's/@HELM_REPO@/%{helm_repo}/g' %{app_staging}/metadata.yaml mkdir -p %{app_staging}/plugins cp /plugins/%{app_name}/*.whl %{app_staging}/plugins -# calculate checksum of all files in app_staging -find . -type f ! -name '*.md5' -print0 | xargs -0 md5sum > checksum.md5 -# package it up -tar -zcf %{_builddir}/%{app_tarball_armada} -C %{app_staging}/ . - -# switch back to source root -cd - - -# Prepare app_staging for fluxcd package -rm -f %{app_staging}/snmp_manifest.yaml - cp -R fluxcd-manifests %{app_staging}/ # calculate checksum of all files in app_staging @@ -99,13 +75,8 @@ rm -fr %{app_staging} %install install -d -m 755 %{buildroot}/%{app_folder} -install -p -D -m 755 %{_builddir}/%{app_tarball_armada} %{buildroot}/%{app_folder} install -p -D -m 755 %{_builddir}/%{app_tarball_fluxcd} %{buildroot}/%{app_folder} -%files armada -%defattr(-,root,root,-) -%{app_folder}/%{app_tarball_armada} - %files %defattr(-,root,root,-) %{app_folder}/%{app_tarball_fluxcd} diff --git a/stx-snmp-helm/debian/deb_folder/control b/stx-snmp-helm/debian/deb_folder/control index bb23504..3553d08 100644 --- a/stx-snmp-helm/debian/deb_folder/control +++ b/stx-snmp-helm/debian/deb_folder/control @@ -13,5 +13,5 @@ Package: stx-snmp-helm Section: libs Architecture: any Depends: ${misc:Depends} -Description: StarlingX SNMP Armada Helm Charts - This package contains Armada helm charts for the SNMP application. +Description: StarlingX SNMP Helm Charts + This package contains helm FluxCD charts for the SNMP application. diff --git a/stx-snmp-helm/debian/deb_folder/rules b/stx-snmp-helm/debian/deb_folder/rules index 631ded4..b8d8982 100755 --- a/stx-snmp-helm/debian/deb_folder/rules +++ b/stx-snmp-helm/debian/deb_folder/rules @@ -10,10 +10,8 @@ export MINOR_PATCH = $(shell echo $(DEB_VERSION) | cut -f 2 -d '.') export APP_NAME = snmp export APP_VERSION = $(MAJOR).$(MINOR_PATCH) -export APP_TARBALL_ARMADA = $(APP_NAME)-armada-$(APP_VERSION).tgz export APP_TARBALL_FLUXCD = $(APP_NAME)-$(APP_VERSION).tgz export HELM_REPO = stx-platform -export STAGING_ARMADA = staging-armada export STAGING_FLUXCD = staging-fluxcd %: @@ -27,33 +25,6 @@ override_dh_auto_build: # Create the TGZ file. cd helm-charts && make - ############ - # ARMADA # - ############ - # Setup the staging directory. - mkdir -p $(STAGING_ARMADA) - cp files/metadata.yaml $(STAGING_ARMADA) - cp manifests/*.yaml $(STAGING_ARMADA) - mkdir -p $(STAGING_ARMADA)/charts - cp helm-charts/*.tgz $(STAGING_ARMADA)/charts - - # Populate metadata. - cd $(STAGING_ARMADA) - sed -i 's/@APP_NAME@/$(APP_NAME)/g' $(STAGING_ARMADA)/metadata.yaml - sed -i 's/@APP_VERSION@/$(APP_VERSION)/g' $(STAGING_ARMADA)/metadata.yaml - sed -i 's/@HELM_REPO@/$(HELM_REPO)/g' $(STAGING_ARMADA)/metadata.yaml - - # Copy the plugins: installed in the buildroot - mkdir -p $(STAGING_ARMADA)/plugins - cp /plugins/$(APP_NAME)/*.whl $(STAGING_ARMADA)/plugins - - # Create the app package. - cd $(STAGING_ARMADA) && find . -type f ! -name '*.md5' -print0 | xargs -0 md5sum > checksum.md5 - tar cfz $(APP_TARBALL_ARMADA) -C $(STAGING_ARMADA)/ . - - # Cleanup staging. - rm -rf $(STAGING_ARMADA) - ############ # FLUXCD # ############ @@ -85,7 +56,6 @@ override_dh_auto_build: override_dh_auto_install: # Install the app tar file. install -d -m 755 $(APP_FOLDER) - install -p -D -m 755 $(APP_TARBALL_ARMADA) $(APP_FOLDER) install -p -D -m 755 $(APP_TARBALL_FLUXCD) $(APP_FOLDER) override_dh_usrlocal: diff --git a/stx-snmp-helm/stx-snmp-helm/manifests/snmp_manifest.yaml b/stx-snmp-helm/stx-snmp-helm/manifests/snmp_manifest.yaml deleted file mode 100644 index 0828229..0000000 --- a/stx-snmp-helm/stx-snmp-helm/manifests/snmp_manifest.yaml +++ /dev/null @@ -1,45 +0,0 @@ ---- -schema: armada/Chart/v1 -metadata: - schema: metadata/Document/v1 - name: snmp -data: - chart_name: snmp - release: snmp - namespace: kube-system - source: - location: http://172.17.0.1:8080/helm_charts/stx-platform/snmp-1.0.0.tgz - subpath: snmp - type: tar - reference: master - wait: - timeout: 1800 - install: - no_hooks: false - upgrade: - no_hooks: false - pre: - delete: - - type: job - labels: - app: snmp - dependencies: [] ---- -schema: armada/ChartGroup/v1 -metadata: - schema: metadata/Document/v1 - name: snmp -data: - description: "StarlingX SNMP" - sequenced: false - chart_group: - - snmp ---- -schema: armada/Manifest/v1 -metadata: - schema: metadata/Document/v1 - name: snmp-manifest -data: - release_prefix: ns - chart_groups: - - snmp