Skip to content

Installing and deploying Helpy on Heroku

Scott Miller edited this page Jan 27, 2019 · 1 revision

Heroku provides a convenient way to run Helpy. This tutorial will walk you through setting up your installation including file storage on S3 (Helpy 2.3+).

Prerequisites

  • An account on Heroku
  • The Heroku toolbelt installed and logged in from the command line.
  • An account on AWS S3 or another S3 compatible file store. This is because Heroku lacks the ability to store files.

1. Clone the repo, and uncomment the 12factor gem.

On your local workstation, you will first need to clone the repo by typing:

git clone https://github.com/helpyio/helpy helpy

Next, switch the the new helpy directory and edit the Gemfile. At the bottom, you will need to uncomment the line:

# Uncomment this gem for Heroku:
# gem 'rails_12factor'

2. Next, bundle install the gem and push to Heroku:

bundle install
heroku login
git push heroku master
heroku run rake db:migrate
heroku run rake db:seed
heroku ps:scale web=1
heroku open

3. Configure Environment variables to store files

Helpy 2.3 and later allows you to easily configure S3 file storage by using environment variables to describe the access keys, endpoints, etc.

  1. In the Heroku control panel, navigate to the settings panel
  2. Click on "Reveal Config Vars" to expose the Environment Variables
  3. Add the following variables, with the values corresponding to your S3 account
REMOTE_STORAGE=true
S3_KEY=<your key>
S3_SECRET=<your secret>
S3_REGION=us-east-1
S3_ENDPOINT=https://s3.us-east-1.amazonaws.com
S3_BUCKET_NAME=your-bucket-name