- ansible
python3 -m pip install ansible
- podman
yum install podman
- Get ibm-spectrum-scale-csi repo
cd /root
git clone https://github.com/IBM/ibm-spectrum-scale-csi.git
- Create public Container Image Repository on quay
i. Go to quay.io and login.
ii. Click the + icon in the top right of the header on any quay.io page and choose 'New Repository'
iii. Select 'Container Image Repository' on the next page
iv. Enter repository name , click on public and and then click the 'Create Public Repository' button.
- Clone this repo
git clone https://github.com/vrushch/auto-olm.git
cd auto-olm
- Disable default operator sources.
oc patch OperatorHub cluster --type json -p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": true}]'
- Edit required values in olm-test-playbook.yaml
QUAY_NAMESPACE: vrushch # this is quay username
PACKAGE_NAME: vrushal-csi-driver-repo-2 # this is Container Image Repository Repository name
# Versions you want to test. Playbook will upload in order and run tests.
OPERATOR_VERSIONS:
- 1.0.0
- 1.1.0
- 2.0.0
- 2.1.0
# Quay username with write access to the application and Quay Password
QUAY_USERNAME: "vrushch"
QUAY_PASSWORD: "XXXXXXXXXX"
# Check OPERATOR_DIR location is correct
OPERATOR_DIR: /root/ibm-spectrum-scale-csi/operator/deploy/olm-catalog/ibm-spectrum-scale-csi-operator
- Run following command
ansible-playbook olm-test-playbook.yaml
- Go to operatorhub listing of your Openshift cluster and install operator. verify operator installtion using
oc get pod -n ibm-spectrum-scale-csi-driver
- Enable default operator sources
oc patch OperatorHub cluster --type json -p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": false}]'
- Delete Repository from quay
Repositories -> repository_name -> setting -> delete repository
- ansible
python3 -m pip install ansible
- docker
yum install docker
- Get ibm-spectrum-scale-csi repo
cd /root
git clone https://github.com/IBM/ibm-spectrum-scale-csi.git
- Create public Container Image Repository on quay
i. Go to quay.io and login.
ii. Click the + icon in the top right of the header on any quay.io page and choose 'New Repository'
iii. Select 'Container Image Repository' on the next page
iv. Enter repository name , click on public and and then click the 'Create Public Repository' button.
- Clone this repo
git clone https://github.com/vrushch/auto-olm.git
cd auto-olm
- Login to quay.io
docker login quay.io
- Run following commands
kubectl apply -f https://github.com/operator-framework/operator-lifecycle-manager/releases/download/0.13.0/crds.yaml
kubectl apply -f https://github.com/operator-framework/operator-lifecycle-manager/releases/download/0.13.0/olm.yaml
- Check for OLM pods
kubectl get pods -n olm
- Delete catalogsource of all operators
kubectl delete catalogsource operatorhubio-catalog -n olm
- Edit required values in k8s-olm-test-playbook.yaml
QUAY_NAMESPACE: vrushch # this is quay username
PACKAGE_NAME: vrushal-csi-driver-repo-2 # this is Container Image Repository Repository name
# Versions you want to test. Playbook will upload in order and run tests.
OPERATOR_VERSIONS:
- 1.0.0
- 1.1.0
- 2.0.0
- 2.1.0
# Check OPERATOR_DIR location is correct
OPERATOR_DIR: /root/ibm-spectrum-scale-csi/operator/deploy/olm-catalog/ibm-spectrum-scale-csi-operator
- Run following command
ansible-playbook k8s-olm-test-playbook.yaml
- Verify operator installtion using
kubectl get pods -n ibm-spectrum-scale-csi-driver
kubectl get csv -n ibm-spectrum-scale-csi-driver
kubectl get sub -n ibm-spectrum-scale-csi-driver
kubectl get ip -n ibm-spectrum-scale-csi-driver
- Cleanup
kubectl delete sub ibm-spectrum-scale-csi-sub -n ibm-spectrum-scale-csi-driver
kubectl delete operatorgroup operatorgroup -n ibm-spectrum-scale-csi-driver
kubectl delete namespace ibm-spectrum-scale-csi-driver #( before this delete the operator and driver)
kubectl delete catalogsource ibm-spectrum-scale-csi -n olm
kubectl delete -f https://github.com/operator-framework/operator-lifecycle-manager/releases/download/0.13.0/crds.yaml
kubectl delete -f https://github.com/operator-framework/operator-lifecycle-manager/releases/download/0.13.0/olm.yaml
- Delete Repository from quay
Repositories -> repository_name -> setting -> delete repository