diff --git a/bin/replicate-mongodb.sh b/bin/replicate-mongodb.sh index 626e8bd8..ab338dc7 100755 --- a/bin/replicate-mongodb.sh +++ b/bin/replicate-mongodb.sh @@ -30,11 +30,11 @@ case "$app" in database="${app//-/_}_production" ;; "asset-manager") - hostname=mongo-normal + hostname=shared-documentdb database=govuk_assets_production ;; *) - hostname=mongo-normal + hostname=shared-documentdb database="${app//-/_}_production" ;; esac @@ -50,7 +50,7 @@ if [[ -e "$archive_path" ]]; then else mkdir -p "$archive_dir" remote_file_name=$(aws s3 ls "s3://${bucket}/${hostname}/" | grep "[[:digit:]]-$database.gz" | tail -n1 | sed 's/^.* .* .* //') - aws s3 cp "s3://${bucket}/${hostname}/${remote_file_name}" "$archive_path" + aws s3 cp "s3://${bucket}/${hostname}/${remote_file_name}" "$archive_path" --recursive fi if [[ -n "${SKIP_IMPORT:-}" ]]; then