Skip to main content
Version: 2.x (Latest)

Deploy on Heroku

Create Instance

Deploy Authorizer with PostgreSQL on Heroku:

Deploy to Heroku

After clicking the button:

Step 1: Enter the App name

The app name becomes your URL. For example, authorizer-demo gives you authorizer-demo.herokuapp.com.

Step 2: Choose the Region and deploy

Select your deployment region (United States or Europe).

Step 3: Configure for v2

For Authorizer v2, configure the following required variables in your Heroku app settings under Config Vars:

VariableExample Value
DATABASE_TYPEpostgres
DATABASE_URL(auto-configured by Heroku add-on)
JWT_TYPEHS256
JWT_SECRETtest
ADMIN_SECRETadmin
CLIENT_ID123456
CLIENT_SECRETsecret

Update the Procfile or startup command to pass CLI flags:

web: ./build/server --database-type=$DATABASE_TYPE --database-url=$DATABASE_URL --jwt-type=$JWT_TYPE --jwt-secret=$JWT_SECRET --admin-secret=$ADMIN_SECRET --client-id=$CLIENT_ID --client-secret=$CLIENT_SECRET

Updating Instance

Prerequisites

Step 1: Clone Authorizer Heroku App

git clone https://github.com/authorizerdev/authorizer-heroku
cd authorizer-heroku

Step 2: Attach Heroku app

# Replace authorizer-heroku with your Heroku app's name
heroku git:remote -a authorizer-heroku
heroku stack:set container -a authorizer-heroku

Step 3: Deploy the latest version

git push heroku main