mirror of
https://github.com/tiredofit/docker-db-backup.git
synced 2025-12-22 13:44:08 +01:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
238b4d852c | ||
|
|
8d6e72eead | ||
|
|
a9037f97ac |
@@ -1,3 +1,9 @@
|
|||||||
|
## 3.10.4 2023-10-11 <thomas-negrault@github>
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
- Use authentication database for MongoDB restores
|
||||||
|
|
||||||
|
|
||||||
## 3.10.3 2023-10-11 <thomas-negrault@github>
|
## 3.10.3 2023-10-11 <thomas-negrault@github>
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|||||||
@@ -925,7 +925,10 @@ case "${r_dbtype}" in
|
|||||||
if [ -n "${r_dbpass}" ] ; then
|
if [ -n "${r_dbpass}" ] ; then
|
||||||
mongo_pass="-p=${r_dbpass}"
|
mongo_pass="-p=${r_dbpass}"
|
||||||
fi
|
fi
|
||||||
mongorestore ${mongo_compression} -d=${r_dbname} -h=${r_dbhost} --port=${r_dbport} ${mongo_user} ${mongo_pass} --archive=${r_filename}
|
if [ -n "${DB_AUTH}" ] ; then
|
||||||
|
mongo_auth_database="--authenticationDatabase=${DB_AUTH}"
|
||||||
|
fi
|
||||||
|
mongorestore ${mongo_compression} -d=${r_dbname} -h=${r_dbhost} --port=${r_dbport} ${mongo_user} ${mongo_pass} --archive=${r_filename} ${mongo_auth_database}
|
||||||
exit_code=$?
|
exit_code=$?
|
||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
|
|||||||
Reference in New Issue
Block a user