Yu-Chieh’s Blog (Y.C. Chang)

Ruby on Rails / Rubygems / FullStack / Git / Mac notes.

Change Default Web Server and Timezone for Heroku

  • add web server gem to your Gemfile
1
2
3
4
5
group :production do
  gem 'pg'
  gem 'rails_12factor'
  gem 'thin' # web server : thin
end
  • bundle it for updating your Gemfile.lock
1
2
3
$ bundle install
$ git add .
$ git commit -am 'bundle and update Gemfile.lock'
  • deploy to heroku
1
$ git push heroku master

done.

  • time zone config for heroku
1
$ heroku config:add TZ=Asia/Taipei

done.

  • for reset pg DB
1
$ heroku pg:reset DATABASE_URL --confirm heroku_app_name

Comments