-
Notifications
You must be signed in to change notification settings - Fork 153
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
Feature/TP1-569: Add Invoke command to copy Staging DB to a specific Review App #12493
Conversation
120beff
to
0403724
Compare
0403724
to
d28dec2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM and works well @AdalbertoMoz! Left one small comment on documenting before merging in. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing work @AdalbertoMoz! Thanks very much for taking this on, I know its going to be very helpful to the team in the future 👍 Approved!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, Thanks Adal!
➤ Simon Acosta Torres commented: PR merged. |
Description
This script is a refined and Python-rewritten version of the one used in the Mofo Cron Repository, with minor changes.
New Command:
I have introduced a new
invoke
command:invoke staging-to-review-app <review_app_name>
. This command allows you to copy the Staging Database to the Review Apps.Benefits of Using the Staging Database
1. Shared S3 Bucket:
Staging shares the same S3 bucket as the Review Apps. This ensures that all S3 assets are displayed correctly, preventing any loss of static files on the pages.
2. Recent Data:
Staging is synced with the Production Database every Monday. Therefore, the data copied to our Review App is always recent and up-to-date.
FAQ
- Is the issue with Review Apps redirecting to Staging resolved?
Yes, this issue is resolved. The cleanup.sql file now includes changes that automatically update the domain and hostnames within the Review App Databases for both Foundation and Mozfest sites.
- Do I need any prerequisites installed to execute the script?
Yes, you need to have the Heroku CLI and psql installed on your local machine. The script will check for these prerequisites and will not start if they are not installed.
Link to sample test page: https://foundation-s-feature-tp-id5474.herokuapp.com/
Related PRs/issues: #12255
Checklist
Pending Steps
Tests- [ ] Is the code I'm adding covered by tests?Changes in Models:- [ ] Did I update or add new fake data?- [ ] Did I squash my migration?- [ ] Are my changes backward-compatible. If not, did I schedule a deploy with the rest of the team?Documentation:- [ ] Is my code documented?- [ ] Did I update the READMEs or wagtail documentation?Merge Method
💡❗Remember to use squash merge when merging non-feature branches into
main
┆Issue is synchronized with this Jira Story