Skip to content

PortlerPorts that sort themselves out.

A local development process runner like a small docker compose, but with automatic port assignment and environment resolution.

Portler

Quick taste

yaml
services:
  postgres:
    image: postgres:16-alpine
    port: 5432
    env:
      POSTGRES_USER: app
      POSTGRES_PASSWORD: app
      POSTGRES_DB: app

  backend:
    command: npm run dev
    cwd: backend
    port: 4000
    port_env: PORT
    depends_on:
      - postgres
    env:
      DATABASE_URL: postgres://app:app@localhost:${postgres.port}/app

  frontend:
    command: npm run dev
    cwd: frontend
    port: 3000
    port_env: PORT
    env:
      VITE_API_URL: backend.url
bash
$ npm install -g portler
$ portler up

SERVICE    PORT    URL
postgres   51234   http://localhost:51234
backend    51235   http://localhost:51235
frontend   51236   http://localhost:51236

Every service gets a free port, backend.url resolves to the backend's real address, and dependents wait for their dependencies to be ready.

Released under the MIT License.