Deploy Permify

Open-source fine-grained authorization inspired by Google Zanzibar

Deploy Permify

/var/lib/postgresql/data

Just deployed

Deploy and Host Permify on Railway

Permify is an open-source authorization service for building and managing fine-grained, scalable access controls for your applications. Inspired by Google Zanzibar, it enables you to implement RBAC, ReBAC, and ABAC patterns in minutes instead of months, with lightning-fast permission checks at scale.

About Hosting Permify

Hosting Permify on Railway provides a complete authorization infrastructure with minimal configuration. The template automatically provisions a dedicated PostgreSQL database for storing authorization schemas, relationship tuples, and permission data. Permify runs as a stateless gRPC/REST service, making it easy to scale horizontally as your application grows.

Both services run on Railway's private network by default, ensuring secure internal communication with zero egress fees. Your application connects to Permify via gRPC (port 3478) or REST (port 3476) to perform permission checks, typically responding in under 10ms. Database migrations run automatically on startup, so you're ready to go immediately after deployment.

Common Use Cases

  • Fine-Grained Access Control: Answer questions like "Can user X edit document Y?" or "Which resources can user Z access?" with low-latency permission checks across your application.

  • Multi-Tenant Authorization: Build isolated permission systems for each organization or tenant in your SaaS application, with complete separation and custom role hierarchies.

  • Role-Based Access Control (RBAC): Implement hierarchical roles with inherited permissions, such as Admin > Manager > Member, with automatic permission propagation.

  • Relationship-Based Access Control (ReBAC): Model complex permission structures based on resource relationships, like Google Drive's folder/file sharing model.

Dependencies for Permify Hosting

  • PostgreSQL Database — Included in this template, configured with private network connections

Deployment Dependencies

Implementation Details

Private Network Communication: All communication between Permify and PostgreSQL occurs over Railway's private network. The database is not accessible from outside the private network by default, which eliminates egress fees and improves security.

Connecting Your Application: Add these environment variables to your application service to connect to Permify:

PERMIFY_HOST=${{Permify.RAILWAY_PRIVATE_DOMAIN}}
PERMIFY_GRPC_PORT=3478
PERMIFY_API_KEY=${{Permify.PERMIFY_API_KEY}}

API Authentication: This template configures Permify with API key authentication enabled. The API key is automatically generated during deployment and should be used by your application to authenticate requests.

Health Checks: Permify exposes a health endpoint at /healthz on port 3476 for monitoring service status.

Why Deploy Permify on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying Permify on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.


Template Content

More templates in this category

View Template
Keycloak
Keycloak template with keywind theme + apple and discord providers

View Template
lua-protector
Test deployed my project first

View Template
bknd
Feature-rich yet lightweight backend