Skip to content

Quick Start

This guide gets you running locally in about 5 minutes using mock services. You don’t need to configure Google OAuth - the mock OAuth server simulates authentication with test users.

Make sure you have these installed:

See System Requirements for detailed installation instructions.

  1. Clone the repository

    Terminal window
    git clone https://github.com/DocSpring/rack-gateway.git
    cd rack-gateway
  2. Install dependencies

    Terminal window
    go mod download
    cd web && bun install && cd ..
  3. Configure environment

    The default configuration uses mock services. Just copy the example file:

    Terminal window
    cp mise.local.toml.example mise.local.toml
  4. Start everything

    Terminal window
    task dev

    This starts:

    • Gateway API server at http://localhost:8447
    • Web UI at http://localhost:5223
    • Mock OAuth server at http://localhost:3345
    • Mock Convox API at http://localhost:5443
    • PostgreSQL database in Docker
  1. Open http://localhost:5223 in your browser

  2. Click “Sign in with Google”

  3. The mock OAuth server shows a user selection screen

  4. Choose a test user:

  5. You’ll be redirected to the dashboard

  1. Login to the gateway

    Terminal window
    ./bin/rack-gateway login staging http://localhost:8447

    Your browser opens to the mock OAuth server. Select a test user.

  2. Run Convox commands

    Terminal window
    # List apps (from mock Convox)
    ./bin/rack-gateway apps
    # View processes
    ./bin/rack-gateway ps
    # Check rack status
    ./bin/rack-gateway rack
  3. Set up a convenient alias

    Terminal window
    alias cg="./bin/rack-gateway"
    cg apps
    cg ps

The development environment consists of:

ComponentURLDescription
Gateway APIhttp://localhost:8447Authentication proxy
Web UIhttp://localhost:5223Admin interface (Vite dev server)
Mock OAuthhttp://localhost:3345Simulates Google OAuth
Mock Convoxhttp://localhost:5443Simulates Convox rack API
PostgreSQLlocalhost:55432Database (in Docker)

The mock OAuth server provides four test users with different roles:

EmailRoleCapabilities
admin@example.comAdminFull access to everything
deployer@example.comDeployerDeploy apps, manage builds and releases
ops@example.comOpsRestart apps, manage processes
viewer@example.comViewerRead-only access
  1. Login as admin@example.com
  2. Go to Users in the sidebar
  3. View all users and their roles
  4. Try changing a user’s role
  1. Go to API Tokens
  2. Create a new token for CI/CD
  3. Note the token permissions match the user’s role
  1. Go to Audit Logs
  2. See all actions you’ve taken
  3. Note that secrets are automatically redacted
  1. Go to Account Security
  2. Try enrolling a TOTP authenticator
  3. View your active sessions

Verify everything is working:

Terminal window
# Run all tests
task test
# Run linters
task lint

Now that you have Rack Gateway running locally:

If you see port conflict errors:

Terminal window
# Stop all services
task docker:down
# Restart
task dev

Ensure Docker is running:

Terminal window
docker ps # Should show rack-gateway-postgres-1

If the container isn’t running:

Terminal window
task docker:reset
task dev

Make sure you’re using the mock OAuth server URLs:

  • Gateway: http://localhost:8447 (not https)
  • OAuth redirect: http://localhost:8447/api/v1/auth/callback

For more help, see Troubleshooting.