Commit 4ada0f8e authored by Dylan Griffith's avatar Dylan Griffith

Use /bin/herokuish in Auto DevOps docs examples

The previous examples did work however they had a problem when the
bin/setup script installed a different bundler version than the one in
your Gemfile.lock.  It is safer to use `/bin/herokuish procfile exec` to
get access to all the environment already installed for your application
instead of installing bundler again.
parent 6189c869
...@@ -582,16 +582,17 @@ Note that a post-install hook means that if any deploy succeeds, ...@@ -582,16 +582,17 @@ Note that a post-install hook means that if any deploy succeeds,
If present, `DB_MIGRATE` will be run as a shell command within an application pod as If present, `DB_MIGRATE` will be run as a shell command within an application pod as
a helm pre-upgrade hook. a helm pre-upgrade hook.
For example, in a Rails application: For example, in a Rails application in an image built with
[Herokuish](https://github.com/gliderlabs/herokuish):
- `DB_INITIALIZE` can be set to `cd /app && RAILS_ENV=production - `DB_INITIALIZE` can be set to `RAILS_ENV=production /bin/herokuish procfile exec bin/rails db:setup`
bin/setup` - `DB_MIGRATE` can be set to `RAILS_ENV=production /bin/herokuish procfile exec bin/rails db:migrate`
- `DB_MIGRATE` can be set to `cd /app && RAILS_ENV=production bin/update`
NOTE: **Note:** NOTE: **Note:**
The `/app` path is the directory of your project inside the docker image Unless you have a `Dockerfile` in your repo, your image is built with
as [configured by Herokuish. You must prefix commands run in these images with `/bin/herokuish
Herokuish](https://github.com/gliderlabs/herokuish#paths) procfile exec` in order to replicate the the environment your application is
run in.
### Auto Monitoring ### Auto Monitoring
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment