Skip to content

Commit

Permalink
specify dump location with emptyDir volume (#2015)
Browse files Browse the repository at this point in the history
* specify dump location with emptyDir volume

Signed-off-by: Ben Luzarraga <[email protected]>

* add scc to backup job

Signed-off-by: Ben Luzarraga <[email protected]>

* change to use service account instead of fsgroup

Signed-off-by: Ben Luzarraga <[email protected]>

* remove additional security context

* update line format

---------

Signed-off-by: Ben Luzarraga <[email protected]>
Co-authored-by: Daniel Fan <[email protected]>
  • Loading branch information
bluzarraga and Daniel-Fan authored Jun 18, 2024
1 parent c791a88 commit b2defff
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions preload_data.sh
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,7 @@ function dumpmongo() {
fi

ibm_mongodb_image=$(${OC} get pod icp-mongodb-0 -n $FROM_NAMESPACE -o=jsonpath='{range .spec.containers[0]}{.image}{end}')

if [[ $z_or_power_ENV == "false" ]]; then
cat <<EOF >$TEMPFILE
apiVersion: batch/v1
Expand Down Expand Up @@ -411,6 +412,7 @@ spec:
secret:
secretName: mongodb-root-ca-cert
restartPolicy: OnFailure
serviceAccountName: ibm-mongodb-operand
EOF
else #s390x environments do not recognize --ssl options
info "Z or Power cluster detected"
Expand Down Expand Up @@ -513,6 +515,7 @@ spec:
secret:
secretName: mongodb-root-ca-cert
restartPolicy: OnFailure
serviceAccountName: ibm-mongodb-operand
EOF
fi

Expand Down Expand Up @@ -682,6 +685,7 @@ spec:
secret:
secretName: mongodb-root-ca-cert
restartPolicy: Never
serviceAccountName: ibm-mongodb-operand
EOF
else
debug1 "Applying z/power restore job"
Expand Down Expand Up @@ -741,6 +745,7 @@ spec:
secret:
secretName: mongodb-root-ca-cert
restartPolicy: Never
serviceAccountName: ibm-mongodb-operand
EOF
fi

Expand Down

0 comments on commit b2defff

Please sign in to comment.