This PR updates the setup_heroku script with the following improvements:
Stop provisioning DEVISE_SECRET_KEY since a separate setting for Devise is not needed with modern versions of Devise and Rails 4+ (cf. https://github.com/plataformatec/devise/pull/2835). The devise.rb initializer has been updated to allow the application to start without ENV['DEVISE_SECRET_KEY'], in which case Devise will use Rails.application.config.secret_key_base (controlled by ENV['SECRET_TOKEN'])
Allow the script to be run idempotently
Check if a Heroku add-on is installed before calling heroku addons:create
Check if SECRET_TOKEN is set before generating one
Use Ruby instead of Python for UUID generation, since this is a Ruby-based project
Coverage remained the same at 99.368% when pulling aa78063b913be8d8ea0d588892265b0e485326a9 on appropriate:update-setup-heroku-script into f0e17d35d39b6e70f9ec7df7b65ebe8de128a5e0 on codeforamerica:master.
Coverage remained the same at 99.368% when pulling 2d7c28575ef81c67f3d6972cc57d1e8ed488c43f on appropriate:update-setup-heroku-script into f0e17d35d39b6e70f9ec7df7b65ebe8de128a5e0 on codeforamerica:master.
Coverage remained the same at 99.368% when pulling ae47886ad9943f5df48b324676c1526dba1116f4 on appropriate:update-setup-heroku-script into e337b7e84e16dde5e836b58de8be3cb1cba460a1 on codeforamerica:master.
Coverage remained the same at 99.368% when pulling ae47886ad9943f5df48b324676c1526dba1116f4 on appropriate:update-setup-heroku-script into e337b7e84e16dde5e836b58de8be3cb1cba460a1 on codeforamerica:master.
This PR updates the
setup_heroku
script with the following improvements:DEVISE_SECRET_KEY
since a separate setting for Devise is not needed with modern versions of Devise and Rails 4+ (cf. https://github.com/plataformatec/devise/pull/2835). Thedevise.rb
initializer has been updated to allow the application to start withoutENV['DEVISE_SECRET_KEY']
, in which case Devise will useRails.application.config.secret_key_base
(controlled byENV['SECRET_TOKEN']
)heroku addons:create
SECRET_TOKEN
is set before generating onequotaguard:starter
addon (cf. #415)