Deploy Hey
Decentralized and permissionless social media app built with Lens Protocol
Just deployed
/var/lib/postgresql/data
Just deployed
Deploy and Host Hey on Railway
Hey is a decentralized, permissionless social media application built on the Lens Protocol. It leverages Web3 technologies, Next.js, and GraphQL to provide a robust, censorship-resistant platform. Hey allows users to connect their wallets, interact with the decentralized social graph, and manage their Web3 social presence.
About Hosting Hey
Hosting Hey on Railway simplifies the deployment of a modern Web3 monorepo stack. Railway manages the underlying infrastructure, allowing this Turborepo-based Node.js application to run seamlessly in the cloud. Deploying Hey involves provisioning a Node.js environment to serve the API and frontend, alongside a PostgreSQL database for backend data management.
Railway's automatic environment variables map directly to Hey's required configuration, such as Lens Protocol keys and internal API secrets. Railway also automatically provisions HTTPS and a public domain, exposing the application securely. The platform easily scales both horizontally and vertically, handling traffic spikes typical in social media applications without requiring manual server configuration.
Common Use Cases
- Decentralized Social Network
- Web3 Community Hub
- Lens Protocol Client Application
Dependencies for Hey Hosting
- Node.js (v22 or higher)
- PostgreSQL
- Lens Protocol (External Web3 Dependency)
Deployment Dependencies
Implementation Details
Public Networking
| Proxy Type | Target Port |
|---|---|
| HTTP Proxy | 4783 |
Environment Variables
| Variable | Required | Description |
|---|---|---|
PORT | Yes | Internal application listening port (Must be set to 4783). |
PRIVATE_KEY | Yes | Private key used to sign Lens Protocol requests. |
SHARED_SECRET | Yes | Token for internal API authorization. |
DATABASE_URL | Yes | Connection string for the PostgreSQL database. |
PORT=4783
PRIVATE_KEY=your_lens_private_key
SHARED_SECRET=your_internal_api_secret
DATABASE_URL=${{Postgres.DATABASE_URL}}
Database
Hey requires a PostgreSQL database to function correctly. To set this up on Railway:
- Right-click on the Railway project canvas or click "New".
- Select "Database" and choose "Add PostgreSQL".
- Add the
DATABASE_URLvariable to your Hey service and use the Railway reference variable${{Postgres.DATABASE_URL}}to securely connect them.
Build & Start commands
Hey is built using a pnpm monorepo architecture. Railway will typically handle Node.js deployments automatically using Nixpacks. If you need to specify custom commands in your service settings, use the following:
- Install Command:
corepack enable && pnpm install - Build Command:
pnpm build - Start Command:
pnpm start
Accessing the Application
To access your deployed Hey instance:
- Open your Hey application service in the Railway dashboard.
- Navigate to Settings.
- Under the Networking section, click "Generate Domain".
- Railway will automatically provision an SSL certificate and provide a public URL to access your decentralized social media app.
Why Deploy Hey 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 Hey 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