ports

ports is a cursor rule for Cursor from louisbrulenaudet/monorepo-template. It costs 0 tokens per session (399 once invoked), scanned A, original, Apache-2.0.

Rules for assigning local development ports to different kinds of applications and services. A port is the number used to reach a program running on your computer.

In plain words
What is it for?
They guide port choices for gateways, frontends, Workers, queue consumers, webhooks, and local MCP servers.
Why use it?
They prevent multiple services from using the same port and keep port settings consistent across configuration files.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit They guide port choices for gateways, frontends, Workers, queue consumers, webhooks, and local MCP servers.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/louisbrulenaudet/monorepo-template/ports
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/louisbrulenaudet/monorepo-template

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ports

README.md
[![agentmods](https://agentmods.dev/badge/rules/louisbrulenaudet/monorepo-template/ports/github.svg)](https://agentmods.dev/rules/louisbrulenaudet/monorepo-template/ports)
Your own site
<a href="https://agentmods.dev/rules/louisbrulenaudet/monorepo-template/ports"><img src="https://agentmods.dev/badge/rules/louisbrulenaudet/monorepo-template/ports/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ports

Your own site · 80×15
<a href="https://agentmods.dev/rules/louisbrulenaudet/monorepo-template/ports"><img src="https://agentmods.dev/badge/rules/louisbrulenaudet/monorepo-template/ports.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 399 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00399
Opus 5.5 $0.00000 $0.00160
Sonnet 5.5 $0.00000 $0.00080
Haiku 4.5 $0.00000 $0.00040

Measured 2mo ago against content hash 0dc315086052, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ports scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/backend/ports.mdc · 24 lines

What it actually says

Local Dev Ports

Role Prefix Local HTTP ports
HTTP gateway worker-api 8700–8709
Business worker (RPC) worker-* 8710–8739
Queue-only consumer queue-* 8740–8759
Webhook ingress webhook-* 8760–8779
MCP server mcp-* 8780–8789
Growth reserve - 8790–8799
Frontend (Vite) front-* 5170–5199 (dev), 4170–4199 (preview)

Assigned: worker-api 8700; front-app 5174 dev, 4174 preview.

  • A new app takes the next free port in its role's range and records it in package.json → monorepo.devPort and in vite.config.ts (server.port with strictPort: true; a frontend also sets preview.port with strictPort: true). cf dev runs the Vite dev server and forwards only --mode, so the port lives in vite.config.ts alone.
  • RPC and queue workers still set a stable server.port for a standalone cf dev, though production gives them no public URL. How several Workers run together locally under cf is settled with the first worker-*.
  • A Worker with code sets cloudflare({ inspectorPort: 0 }) (ephemeral), so parallel dev servers never collide on an inspector port.
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago Changed · -13 lines · -539 tokens per session 0dc315086052
  2. 2mo ago Changed d84420199051
  3. 3mo ago First seen · 37 lines · 539 tokens per session scan A 356c80d5e403

Subscribe to this mod's changes

ports is a cursor rule published in the GitHub repository louisbrulenaudet/monorepo-template (19 stars, last pushed 8d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 399 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

ports compared with cursor rules from other repositories

ports next to 6 cursor rules from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
portslouisbrulenaudet/monorepo-templateCursor rule198d agoApache-2.0A0Cursor
paperfitOpenRaiser/PaperFitCursor rule33726d agoMITA0Cursor
teamJkudjo/oh-my-cursorCursor rule117d agoMITA13Cursor
chaosJkudjo/oh-my-cursorCursor rule117d agoMITA14Cursor
resumeJkudjo/oh-my-cursorCursor rule117d agoMITA14Cursor
git-masterJkudjo/oh-my-cursorCursor rule117d agoMITA14Cursor
pipelineJkudjo/oh-my-cursorCursor rule117d agoMITA16Cursor