Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix MongoDB replication for 'other' apps #697

Merged
merged 1 commit into from
Nov 3, 2023

Conversation

ollietreend
Copy link
Contributor

Some apps have special rules defined in the MongoDB replication script because their database dumps are stored in a special location.

For everything else, there's a bucket called "mongo-normal" in the S3 bucket "govuk-integration-database-backups". For example, the database backups for Travel Advice Publisher are stored under "s3://govuk-integration-database-backups/mongo-normal/".

It looks like the "mongo-normal" directory used to be called "mongo". But that seems to have changed and the MongoDB replication script in this repo has fallen out of date.

Following this change, I'm now able to successfully replicate the Mongo database for Travel Advice Publisher using the command:

gds aws govuk-integration-readonly bin/replicate-mongodb.sh travel-advice-publisher

Some apps have special rules defined in the MongoDB replication script
because their database dumps are stored in a special location.

For everything else, there's a bucket called "mongo-normal" in the S3
bucket "govuk-integration-database-backups". For example, the database
backups for Travel Advice Publisher are stored under
"s3://govuk-integration-database-backups/mongo-normal/".

It looks like the "mongo-normal" directory used to be called "mongo".
But that seems to have changed and the MongoDB replication script in
this repo has fallen out of date.

Following this change, I'm now able to successfully replicate the Mongo
database for Travel Advice Publisher using the command:

```
gds aws govuk-integration-readonly bin/replicate-mongodb.sh travel-advice-publisher
```
@ollietreend
Copy link
Contributor Author

ollietreend commented Nov 3, 2023

This PR relates to #669. However I believe that PR is still required because Asset Manager seems to have a non-standard filename for its database dumps (i.e. govuk_assets_production rather than asset_manager_production, which is what the * wildcard rule would look for).

@ollietreend ollietreend merged commit 927eb61 into main Nov 3, 2023
2 checks passed
@ollietreend ollietreend deleted the fix-mongodb-replication branch November 3, 2023 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants