Prerequisites
Before you begin, ensure you have the following installed:- Node.js 20+ - Runtime environment
- pnpm 10 - Package manager
- Docker - For running local Postgres
- Slack app credentials - For OAuth authentication
- Cloudflare account - With API token for tunnel + DNS permissions
Quick Start
Follow these steps to get rs-tunnel running on your local machine:Install dependencies
Install all workspace dependencies using pnpm:This installs dependencies for all packages in the monorepo.
Start Postgres
Start the local Postgres database using Docker Compose:This starts Postgres on port
23432 (mapped from container port 5432).Configure environment variables
Create a
.env file in the repository root or in apps/api/.env:See
.env.example in the repository root for a complete list of available configuration options.Running the CLI Locally
To test CLI commands against your local API:The CLI accepts a
--domain flag to override the API URL per command. This setting is persisted to ~/.rs-tunnel/config.json for future runs.Turbo Monorepo Commands
The project uses Turborepo for efficient task orchestration. Run commands from the repository root:Development Mode
Quality Checks
Common Issues
Cannot find module '@ripeseed/shared'
Cannot find module '@ripeseed/shared'
Can't find meta/_journal.json during migrate
Can't find meta/_journal.json during migrate
Ensure the Drizzle migration metadata exists:If missing, you may need to regenerate migrations.
client password must be a string
client password must be a string
Your
DATABASE_URL is not properly configured or loaded.- Verify
.envexists in repo root orapps/api/.env - Check that
DATABASE_URLis complete and properly formatted - Ensure Docker Postgres is running on the correct port (23432)
CLI tests fail with listen EPERM
CLI tests fail with listen EPERM
The
apps/cli/src/lib/local-proxy.test.ts test suite requires permission to bind to local sockets.Run tests in a normal local shell with appropriate permissions. This typically occurs in restricted or sandboxed environments.Slack OAuth callback fails
Slack OAuth callback fails
Ensure
SLACK_REDIRECT_URI in your .env exactly matches the redirect URI configured in your Slack app settings:Next Steps
Monorepo Structure
Learn about the workspace structure and dependencies
Testing
Understand the testing strategy and run tests
Contributing
Learn how to contribute to rs-tunnel
API Reference
Explore the API endpoints

