@@ -10,19 +10,19 @@ run_backup() {
10
10
local storage=$1
11
11
local backup_name=$2
12
12
13
- cat $test_dir /conf/backup.yml |
14
- $sed -e " s/name:/name: ${backup_name} /" |
15
- $sed -e " s/storageName:/storageName: ${storage} /" |
16
- kubectl_bin apply -f -
13
+ cat $test_dir /conf/backup.yml \
14
+ | $sed -e " s/name:/name: ${backup_name} /" \
15
+ | $sed -e " s/storageName:/storageName: ${storage} /" \
16
+ | kubectl_bin apply -f -
17
17
}
18
18
19
19
run_restore () {
20
20
local backup_name=$1
21
21
22
- cat $test_dir /conf/restore.yml |
23
- $sed -e " s/name:/name: restore-${backup_name} /" |
24
- $sed -e " s/backupName:/backupName: ${backup_name} /" |
25
- kubectl_bin apply -f -
22
+ cat $test_dir /conf/restore.yml \
23
+ | $sed -e " s/name:/name: restore-${backup_name} /" \
24
+ | $sed -e " s/backupName:/backupName: ${backup_name} /" \
25
+ | kubectl_bin apply -f -
26
26
}
27
27
28
28
run_recovery_check () {
@@ -44,6 +44,7 @@ run_recovery_check() {
44
44
echo
45
45
46
46
wait_cluster_consistency ${cluster} 42
47
+ sleep 5
47
48
wait_for_pbm_operations ${cluster}
48
49
49
50
compare_mongos_cmd " find" " myApp:myPass@${cluster} -mongos.${namespace} " " -sharded"
@@ -78,8 +79,8 @@ wait_for_running ${cluster}-cfg 3
78
79
wait_for_running ${cluster} -mongos 3
79
80
wait_cluster_consistency ${cluster}
80
81
81
- lbEndpoint=$( kubectl_bin get svc $cluster -mongos -o=jsonpath=' {.status}' |
82
- jq -r ' select(.loadBalancer != null and .loadBalancer.ingress != null and .loadBalancer.ingress != []) | .loadBalancer.ingress[0] | if .ip then .ip else .hostname end' )
82
+ lbEndpoint=$( kubectl_bin get svc $cluster -mongos -o=jsonpath=' {.status}' \
83
+ | jq -r ' select(.loadBalancer != null and .loadBalancer.ingress != null and .loadBalancer.ingress != []) | .loadBalancer.ingress[0] | if .ip then .ip else .hostname end' )
83
84
if [ -z $lbEndpoint ]; then
84
85
echo " mongos service not exported correctly"
85
86
exit 1
0 commit comments