diff options
author | Brian Freeman <bf1936@att.com> | 2019-08-15 09:30:55 -0500 |
---|---|---|
committer | Brian Freeman <bf1936@att.com> | 2019-08-15 09:31:04 -0500 |
commit | 6caf15bc6aaac7d746c6f78b1b25b85f476e253d (patch) | |
tree | 7b1db5564d4bd0d53c57673751d4311eda2b943d /deployment/heat/onap-rke | |
parent | fa357dfc37bb5a71689a8390a287f7ec74a3fdd9 (diff) |
add -n onap and job to cleanup
Issue-ID: INT-1204
Change-Id: I907bb48c2eee62d9448c99a49e4446771113ceff
Signed-off-by: Brian Freeman <bf1936@att.com>
Diffstat (limited to 'deployment/heat/onap-rke')
-rwxr-xr-x | deployment/heat/onap-rke/scripts/cleanup.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/deployment/heat/onap-rke/scripts/cleanup.sh b/deployment/heat/onap-rke/scripts/cleanup.sh index 7d8dd5c68..f602c70a9 100755 --- a/deployment/heat/onap-rke/scripts/cleanup.sh +++ b/deployment/heat/onap-rke/scripts/cleanup.sh @@ -17,23 +17,23 @@ fi if [ $COMPONENT == "sdc" ] || [ $COMPONENT == "SDC" ]; then for keyspace in sdctitan sdcrepository sdcartifact sdccomponent sdcaudit; do - kubectl exec dev-cassandra-cassandra-0 -- cqlsh -u cassandra -p cassandra -e "drop keyspace ${keyspace}" + kubectl -n onap exec dev-cassandra-cassandra-0 -- cqlsh -u cassandra -p cassandra -e "drop keyspace ${keyspace}" done fi if [ $COMPONENT == "so" ] || [ $COMPONENT == "SO" ]; then for database in camundabpmn catalogdb requestdb; do - kubectl exec dev-mariadb-galera-mariadb-galera-0 -- mysql -uroot -psecretpassword -e "drop database ${database}" + kubectl -n onap exec dev-mariadb-galera-mariadb-galera-0 -- mysql -uroot -psecretpassword -e "drop database ${database}" done fi if [ $COMPONENT == "sdnc" ] || [ $COMPONENT == "SDNC" ]; then for database in sdnctl; do - kubectl exec dev-mariadb-galera-mariadb-galera-0 -- mysql -uroot -psecretpassword -e "drop database ${database}" + kubectl -n onap exec dev-mariadb-galera-mariadb-galera-0 -- mysql -uroot -psecretpassword -e "drop database ${database}" done fi -for op in secrets configmaps pvc pv services deployments statefulsets clusterrolebinding; do +for op in secrets configmaps pvc pv services deployments statefulsets clusterrolebinding job; do ARRAY=(`kubectl get $op -n onap | grep dev-$COMPONENT | awk '{print $1}'`) for i in ${ARRAY[*]}; do kubectl delete $op -n onap $i |