File tree Expand file tree Collapse file tree 2 files changed +25
-2
lines changed
tests/kuttl/test-suites/default/watcher Expand file tree Collapse file tree 2 files changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -10,10 +10,14 @@ spec:
1010 databaseInstance : openstack
1111 passwordSelectors :
1212 service : WatcherPassword
13+ customServiceConfig : |
14+ # Global config
1315 secret : osp-secret
1416 apiServiceTemplate :
1517 replicas : 2
1618 resources : {}
19+ customServiceConfig : |
20+ # Service config
1721status :
1822 apiServiceReadyCount : 2
1923 conditions :
@@ -227,3 +231,18 @@ spec:
227231status :
228232 readyReplicas : 2
229233 replicas : 2
234+ ---
235+ apiVersion : kuttl.dev/v1beta1
236+ kind : TestAssert
237+ namespaced : true
238+ commands :
239+ - script : |
240+ set -euxo pipefail
241+ oc project watcher-kuttl-default
242+ APIPOD=$(oc get pods -n watcher-kuttl-default -l "service=watcher-api" -ocustom-columns=:metadata.name|grep -v ^$|head -1)
243+ if [ -n "${APIPOD}" ]; then
244+ [ $(echo $(oc rsh -c watcher-api ${APIPOD} cat /etc/watcher/watcher.conf.d/01-global-custom.conf) |grep -c "^# Global config") == 1 ]
245+ [ $(echo $(oc rsh -c watcher-api ${APIPOD} cat /etc/watcher/watcher.conf.d/02-service-custom.conf) |grep -c "^# Service config") == 1 ]
246+ else
247+ exit 1
248+ fi
Original file line number Diff line number Diff line change @@ -6,7 +6,11 @@ metadata:
66spec :
77 databaseInstance : " openstack"
88 databaseAccount : watcher-precreated
9- apiServiceTemplate :
10- replicas : 2
119 tls :
1210 caBundleSecretName : " combined-ca-bundle"
11+ customServiceConfig : |
12+ # Global config
13+ apiServiceTemplate :
14+ replicas : 2
15+ customServiceConfig : |
16+ # Service config
You can’t perform that action at this time.
0 commit comments