-
Notifications
You must be signed in to change notification settings - Fork 0
Heroku deployment
Code is here-o: https://gist.github.com/fc15181ea9c3b5a297ed
The high level is we have a shell script that CI runs and pushes to master when the build is "GREEN"
CI auto-tags each successful run of the tests and then POST build task kicks off and deploys to staging.
We have it setup to run rake db:seed on every push to staging/production after running db:migrate.
This means that db:seed should be written such that it can be run in an idempotent* way - that is it only makes changes one and only one time. If you don't know what that means - talk to Judy or Bonnie or Mason for ways that they check to see if the seed has happened.
There is a rake task :
rake deploy:production which will ask you for a the tag to deploy. The rake task peels back the tag into a commit in a way that git understands : ^{commit}
Right now we are making a chore when the stories are accepted with the current staging build and then inputing that tag as the entry for rake deploy:production.
IE CI Builds - tags jenkins-Ananse-52 - we do acceptance on staging - and then make a chore that has the name of of the tag : "push 'jenkins-Ananse-52' to production.
We are using 'heroku_san' to greatly simplify the complexity of working with an configuring heroku accounts.
- Idempotent relating to or being a mathematical quantity which when applied to itself under a given binary operation (as multiplication) equals itself; also : relating to or being an operation under which a mathematical quantity is idempotent