docbrown/config/initializers/initialization_cachebust.rb
Ben Halpern 45fb6504dc
[deploy] Replace HEROKU_SLUG_COMMIT with custom footprint (naive) (#9904)
* Replace HEROKU_SLUG_COMMIT with custom footprint (naive)

* Fully set RELEASE_FOOTPRINT with the expectation of setting it before launch

* Change tests

* Fix cache
2020-08-25 13:47:14 -04:00

8 lines
391 B
Ruby

# Trigger cache purges for globally-cached endpoints that could have changed
CacheBuster.bust("/shell_top")
CacheBuster.bust("/shell_bottom")
CacheBuster.bust("/async_info/shell_version")
CacheBuster.bust("/onboarding")
# We will set RELEASE_FOOTPRINT in our Forem Cloud environment, or use HEROKU_SLUG_COMMIT if set (e.g. Heroku env)
ENV["RELEASE_FOOTPRINT"] ||= ENV["HEROKU_SLUG_COMMIT"]