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

Deploy on Render

Introduction

Render is a unified cloud to build and run all your apps and websites with free SSL, a global CDN, DDoS protection, private networks, and auto-deploys from Git.

Requirements

A Render account.

Deploy an Authorizer Instance

Deploy a production-ready Authorizer instance with a managed PostgreSQL database:

Deploy to Render

If you already have a PostgreSQL instance, use the without-postgres branch.

Step 1: Enter app details

Enter the name for your instance.

Render step 1

Step 2: Configure for v2

Set the following required environment variables:

VariableExample Value
DATABASE_TYPEpostgres
DATABASE_URL(auto-configured by Render)
JWT_TYPEHS256
JWT_SECRETtest
ADMIN_SECRETadmin
CLIENT_ID123456
CLIENT_SECRETsecret

Optional: metrics bind address and rate limits

The authorizer-render image expands these variables to CLI flags:

VariableMaps toDefault
METRICS_HOST--metrics-host127.0.0.1
METRICS_PORT--metrics-port8081
RATE_LIMIT_RPS--rate-limit-rps30
RATE_LIMIT_BURST--rate-limit-burst20
RATE_LIMIT_FAIL_CLOSED--rate-limit-fail-closedfalse

See Metrics & monitoring and Rate limiting. Add REDIS_URL if you run more than one instance.

Update the start command to pass CLI flags:

./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

Render step 2