Skip to content

Commit

Permalink
review changes
Browse files Browse the repository at this point in the history
Signed-off-by: ira-pandey1 <[email protected]>
  • Loading branch information
irapandey committed Dec 2, 2024
1 parent 41c3eac commit 2cc1088
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 21 deletions.
36 changes: 18 additions & 18 deletions playbooks/roles/ocp-csi-driver/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,24 @@ Requirements
- Running OCP 4.x cluster is needed.
- Cluster must not contain default StorageClass.
- Optional :
- A secret with PowerVC certificate in the `default` namespace
Secret name should be `powervc-certificate` and must contains `certificate` field.
eg.

```
apiVersion: v1
kind: Secret
metadata:
name: powervc-certificate
namespace: default
type: Opaque
stringData:
certificate: |
-----BEGIN CERTIFICATE-----
IBAgwIBUCCAwIBAgIUn2gAbw0LWHtozBNiLdUtELvr1pyPAzcNAQYjAwDQYJKoZIhv
...
Un2gAIBAb -----END CERTIFICATE-----
```
- A secret with PowerVC certificate in the `default` namespace
Secret name should be `powervc-certificate` and must contains `certificate` field.
eg.

```
apiVersion: v1
kind: Secret
metadata:
name: powervc-certificate
namespace: default
type: Opaque
stringData:
certificate: |
-----BEGIN CERTIFICATE-----
IBAgwIBUCCAwIBAgIUn2gAbw0LWHtozBNiLdUtELvr1pyPAzcNAQYjAwDQYJKoZIhv
...
Un2gAIBAb -----END CERTIFICATE-----
```

Role Variables
--------------
Expand Down
6 changes: 3 additions & 3 deletions playbooks/roles/ocp-csi-driver/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,12 @@
msg: "PowerVC certificate secret is not present!"
when: powervc_certificate.resources | length == 0

- name: If powervc-certificate is empty
debug:
- debug:
msg: "PowerVC certificate is empty! Please check the certificate's secret."
when: >
(powervc_certificate.resources[0].data.certificate is not defined) or
(powervc_certificate.resources[0].data.certificate | length == 0)
(powervc_certificate.resources[0].data.certificate | length == 0) or
(powervc_certificate.resources | length != 0)
- name: Create namespace for CSI driver validation
k8s:
Expand Down

0 comments on commit 2cc1088

Please sign in to comment.