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

updating DB and picklebase on server start #695

Merged
merged 2 commits into from
Jun 17, 2020
Merged

Conversation

jmensch1
Copy link
Contributor

@jmensch1 jmensch1 commented Jun 17, 2020

This does a background update of the database and the picklebase when the server starts, provided the UPDATE_ON_START env var is set to 1. That var is really just a proxy for "are we running on heroku?"

The reason we need to update when the server starts, instead of running a cron job, is that heroku wipes out the filesystem, and with it the picklebase, whenever the server restarts. The server automatically restarts every 24 hours, so that's a convenient time to update the database as well.

Once this is merged to dev, we can do a push to master.

UPDATE:
I tweaked the backend workflow a bit to (hopefully) make the registry publishing work correctly.

  • Up to date with dev branch
  • Branch name follows guidelines
  • All PR Status checks are successful
  • Peer reviewed and approved

Any questions? See the getting started guide

@jmensch1 jmensch1 requested a review from adamkendis June 17, 2020 17:22
Copy link
Member

@adamkendis adamkendis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@adamkendis adamkendis merged commit 43c4a06 into dev Jun 17, 2020
@adamkendis adamkendis deleted the BACK-HerokuUpdating branch June 17, 2020 19:22
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