remove CentOS build of vault

Disables the packages for CentOS build, as well as the vault manager
image.  Conversion of docker image to Debian will happen at a later
date (task 46869).

Test Plan:
PASS: centos build
PASS: debian build

Story: 2010393
Task: 46868

Change-Id: I827352122460976b07b436fb022741f7d89e5548
Signed-off-by: Michel Thebeau <michel.thebeau@windriver.com>
This commit is contained in:
Michel Thebeau 2022-11-15 14:23:31 -05:00
parent 03235cce70
commit 20167fc54f
14 changed files with 0 additions and 315 deletions

View File

@ -1 +0,0 @@
flock

View File

@ -1 +0,0 @@
stx-vault-helm

View File

@ -1,3 +0,0 @@
stx-vault-helm
vault-helm
python-k8sapp-vault

View File

@ -1,2 +0,0 @@
stx-vault-helm
python-k8sapp-vault

View File

@ -1 +0,0 @@
stx-vault-helm

View File

@ -1,2 +0,0 @@
helm-charts-vault-0-6-0.tar.gz#helm-charts-vault#https://github.com/hashicorp/vault-helm/archive/v0.6.0.tar.gz#http##
helm-charts-vault-0-19-0.tar.gz#helm-charts-vault#https://github.com/hashicorp/vault-helm/archive/v0.19.0.tar.gz#http##

View File

@ -1,7 +0,0 @@
SRC_DIR="k8sapp_vault"
# Keep the SRCREV in sync with stx-vault-helm so the app version is the
# same as the plugin version
TIS_BASE_SRCREV=77715cf9146c04c401e6fdae51cd865953f82ef4
TIS_PATCH_VER=GITREVCOUNT

View File

@ -1,52 +0,0 @@
%global app_name vault
%global pypi_name k8sapp-vault
%global sname k8sapp_vault
Name: python-%{pypi_name}
Version: 20.06
Release: %{tis_patch_ver}%{?_tis_dist}
Summary: StarlingX sysinv extensions: Vault
License: Apache-2.0
Source0: %{name}-%{version}.tar.gz
BuildArch: noarch
BuildRequires: python-setuptools
BuildRequires: python-pbr
BuildRequires: python2-pip
BuildRequires: python2-wheel
%description
StarlingX sysinv extensions: Vault K8S app
%prep
%setup
# Remove bundled egg-info
rm -rf %{pypi_name}.egg-info
%build
export PBR_VERSION=%{version}
%{__python2} setup.py build
%py2_build_wheel
%install
export PBR_VERSION=%{version}.%{tis_patch_ver}
export SKIP_PIP_INSTALL=1
%{__python2} setup.py install --skip-build --root %{buildroot}
mkdir -p ${RPM_BUILD_ROOT}/plugins/%{app_name}
install -m 644 dist/*.whl ${RPM_BUILD_ROOT}/plugins/%{app_name}/
%files
%{python2_sitelib}/%{sname}
%{python2_sitelib}/%{sname}-*.egg-info
%package wheels
Summary: %{name} wheels
%description wheels
Contains python wheels for %{name}
%files wheels
/plugins/*

View File

@ -1,15 +0,0 @@
SRC_DIR="stx-vault-helm"
TAR_NAME=helm-charts-vault-0-19-0
VERSION=1.0.0
TAR="$TAR_NAME.tar.gz"
COPY_LIST_TO_TAR="\
$STX_BASE/helm-charts/psp-rolebinding/psp-rolebinding/helm-charts \
"
#COPY_LIST="${CGCS_BASE}/downloads/$TAR $PKG_BASE/$SRC_DIR/files/* $PKG_BASE/$SRC_DIR/manifests/* $PKG_BASE/$SRC_DIR/helm-charts/*"
# Keep the SRCREV in sync with python-k8sapp-vault so the app version is
# the same as the plugin version
TIS_BASE_SRCREV=77715cf9146c04c401e6fdae51cd865953f82ef4
TIS_PATCH_VER=GITREVCOUNT

View File

@ -1,16 +0,0 @@
ARG BASE
FROM ${BASE}
ARG STX_REPO_FILE=/etc/yum.repos.d/stx.repo
ENV KUBE_LATEST_VERSION="v1.18.3"
RUN set -ex ;\
yum install --disablerepo=* \
$(grep '^name=' ${STX_REPO_FILE} | awk -F '=' '{printf "--enablerepo=" $2 " "}') \
-y \
curl jq \
&& curl -L https://storage.googleapis.com/kubernetes-release/release/${KUBE_LATEST_VERSION}/bin/linux/amd64/kubectl -o /usr/local/bin/kubectl \
&& chmod +x /usr/local/bin/kubectl
CMD ["bash"]

View File

@ -1,106 +0,0 @@
# Application tunables (maps to metadata)
%global app_name vault
%global helm_repo stx-platform
# Install location
%global app_folder /usr/local/share/applications/helm
# Build variables
%global helm_folder /usr/lib/helm
%global toolkit_version 0.1.0
Summary: StarlingX Vault FluxCD Helm Charts
Name: stx-vault-helm
Version: 1.0
Release: %{tis_patch_ver}%{?_tis_dist}
License: Apache-2.0
Group: base
Packager: Wind River <info@windriver.com>
URL: unknown
# External helm chart source
Source0: helm-charts-vault-0-19-0.tar.gz
# psp-rolebinding source from stx/helm-charts/psp-rolebinding
# plugins source from stx/vault-armada-app/python-k8sapp-vault
BuildArch: noarch
BuildRequires: helm
BuildRequires: chartmuseum
BuildRequires: vault-helm
BuildRequires: python-k8sapp-vault
BuildRequires: python-k8sapp-vault-wheels
%description
StarlingX Vault FluxCD Helm Charts
%prep
%setup -n helm-charts-vault-0-19-0-1.0.0
%build
chartmuseum --debug --port=8879 --context-path='/charts' --storage="local" --storage-local-rootdir="." &
sleep 2
helm repo add local http://localhost:8879/charts
# psp-rolebinding source is copied by the function of build_srpm.data
# COPY_LIST_TO_TAR
cd helm-charts
make psp-rolebinding
# switch back to source root
cd -
# Terminate helm server (the last backgrounded task)
kill %1
# Create a chart tarball compliant with sysinv kube-app.py
%define app_staging %{_builddir}/staging
%define app_tarball_fluxcd %{app_name}-%{version}-%{tis_patch_ver}.tgz
# Setup staging
mkdir -p %{app_staging}
cp files/metadata.yaml %{app_staging}
mkdir -p %{app_staging}/charts
# copy psp-rolebinding tar
cp helm-charts/*.tgz %{app_staging}/charts
# copy vault tar built by vault-helm/centos/vault-helm.spec
cp %{helm_folder}/vault*.tgz %{app_staging}/charts
# Populate metadata
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
# Copy the plugins: installed in the buildroot
# built by python-k8sapp-vault/centos/python-k8sapp-vault.spec
mkdir -p %{app_staging}/plugins
cp /plugins/%{app_name}/*.whl %{app_staging}/plugins
# Prepare app_staging for fluxcd package
cp -R fluxcd-manifests %{app_staging}/
# calculate checksum of all files in app_staging
cd %{app_staging}
find . -type f ! -name '*.md5' -print0 | xargs -0 md5sum > checksum.md5
# package fluxcd app
tar -zcf %{_builddir}/%{app_tarball_fluxcd} -C %{app_staging}/ .
# switch back to source root
cd -
# Cleanup staging
rm -fr %{app_staging}
%install
install -d -m 755 %{buildroot}/%{app_folder}
install -p -D -m 755 %{_builddir}/%{app_tarball_fluxcd} %{buildroot}/%{app_folder}
%files
%defattr(-,root,root,-)
%{app_folder}/%{app_tarball_fluxcd}

View File

@ -1,2 +0,0 @@
BUILDER=docker
LABEL=stx-vault-manager

View File

@ -1,12 +0,0 @@
SRC_DIR="vault-helm"
TAR_NAME=helm-charts-vault-0-19-0
VERSION=1.0.0
TAR="$TAR_NAME.tar.gz"
COPY_LIST="${CGCS_BASE}/downloads/$TAR $PKG_BASE/$SRC_DIR/files/* $PKG_BASE/$SRC_DIR/helm-charts/*"
# Keep the SRCREV in sync with python-k8sapp-vault so the app version is
# the same as the plugin version
TIS_BASE_SRCREV=77715cf9146c04c401e6fdae51cd865953f82ef4
TIS_PATCH_VER=GITREVCOUNT

View File

@ -1,95 +0,0 @@
# Application tunables (maps to metadata)
%global app_name vault
%global helm_repo stx-platform
%global armada_folder /usr/lib/armada
# Install location
%global app_folder /usr/local/share/applications/helm
# Build variables
%global helm_folder /usr/lib/helm
%global toolkit_version 0.1.0
Summary: StarlingX Vault Armada Helm Charts
Name: vault-helm
Version: 1.0
Release: %{tis_patch_ver}%{?_tis_dist}
License: Apache-2.0
Group: base
Packager: Wind River <info@windriver.com>
URL: unknown
Source0: helm-charts-vault-0-19-0.tar.gz
Source1: repositories.yaml
Source2: index.yaml
Source3: Makefile
Source4: metadata.yaml
Source5: vault-init.yaml
Source6: vault-certificates.yaml
Source7: _helpers-CA.tpl
BuildArch: noarch
Patch01: 0001-Add-vault-manager-repository-to-values.yaml.patch
BuildRequires: helm
BuildRequires: chartmuseum
%description
StarlingX Vault Helm Charts
%prep
%setup -n helm-charts-vault
%patch01 -p1
%build
chartmuseum --debug --port=8879 --context-path='/charts' --storage="local" --storage-local-rootdir="." &
sleep 2
helm repo add local http://localhost:8879/charts
# Create the tgz file
cp %{SOURCE3} ./
mkdir ./vault
cp ./Chart.yaml ./vault
mv ./values.yaml ./vault
cp %{SOURCE5} ./templates
cp %{SOURCE6} ./templates
cat %{SOURCE7} >> ./templates/_helpers.tpl
mv ./templates ./vault/templates
make vault
cd -
# Terminate helm server (the last backgrounded task)
kill %1
# Create a chart tarball compliant with sysinv kube-app.py
#%define app_staging %{_builddir}/staging
#%define app_tarball %{app_name}-%{version}-%{tis_patch_ver}.tgz
# Setup staging
mkdir -p %{app_staging}
cp %{SOURCE4} %{app_staging}
mkdir -p %{app_staging}/charts
cp ./helm-charts-vault/*.tgz %{app_staging}/charts
cd %{app_staging}
# package it up
find . -type f ! -name '*.md5' -print0 | xargs -0 md5sum > checksum.md5
tar -zcf %{_builddir}/%{app_tarball} -C %{app_staging}/ .
# Cleanup staging
#rm -fr %{app_staging}
%install
install -d -m 755 ${RPM_BUILD_ROOT}%{helm_folder}
install -p -D -m 755 %{app_staging}/charts/*.tgz ${RPM_BUILD_ROOT}%{helm_folder}
%files
%defattr(-,root,root,-)
%{helm_folder}/*