Urgent.News

What's breaking now, across hundreds of outlets.

Tech

Why Your Local App Is on Port 8080 (and 7 Other Local Port Surprises)

You expected localhost . You got localhost:8080 , or a database on 15433, and the connection string in your notes no longer works. Local ports are quiet sources of confusion. Here are eight surprises. 80 is often taken. Another web server, a VPN client, a dev proxy. Flisk falls back to 8080 for HTTP and 8443 for HTTPS, and prints the URLs. 5432 is the usual Postgres collision. A database you…

When working with localhost, it is common to encounter unexpected port numbers. Eight surprising port assignments are discussed here. Port 80 is frequently used, often by web servers, VPN clients, or dev proxies. If it is taken, Flisk, a tool, defaults to port 8080 for HTTP and 8443 for HTTPS. The URLs are displayed by Flisk after it chooses these ports.

The database port 5432 is another frequently used number, especially for Postgres. Any database installed previously might still be active on this port. The port is included in the URL itself, so copying an old URL without specifying the port will lead to the wrong location. To ensure the correct port is used, one can set the environment variable FLISK_HTTP_PORT=80 before running flisk up.

If port 80 is occupied, Flisk will indicate this. You can specify the desired port directly in the URL. For easier identification, .localhost names can be used, such as api.my-project.localhost:8080. Performing a dry run with flisk up --dry-run will display the ports that would be used before any building takes place. The ports freed by flisk down are made available for new applications.

If an old Tilt instance is still running and using ports, flisk up --force can terminate it. It is advisable not to hard-code ports in configuration files. Instead, retrieve them from the output or the gateway name. To quickly check which process is using a specific port, use the command lsof -i :5432 on macOS and Linux. Depending on the outcome, you can choose to stop that process or switch to the fallback port.

Understanding and documenting port assignments can simplify debugging and ensure seamless operations.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

Report a problem with this story

More in Tech

Marketplace App Backups: User Uploads, Database Dumps, Object Storage, and Expiry

Short answer: build each nightly backup as a closed recovery set containing a database dump, the referenced user uploads, and a signed manifest; authorize restoration of that set as one operation, but…

  • Backups include database dumps, user uploads, and signed manifests
  • Organized in private namespace by backupid and artifact class
  • Restoration requires signed document and is audited

So You’ve Heard About Flock. Now What? 🤔

Automated license plate readers (ALPRs) are quietly turning public roads into surveillance checkpoints. Every passing car gets photographed, logged, and stored in order to build a record of where the…

10 Things That Break When You Run Many Services on One Laptop (and the Fix for Each)

Running two services locally is easy. Running ten is a different job. Nothing is hard on its own, but the small failures stack up, and they all look like "it just doesn't start".

  • Disk space issues can prevent build process from completing
  • Port conflicts cause Flisk to fallback to free port ranges
  • Starting many services simultaneously causes resource contention

Bookmark This: The Local Dev Checklist Before You Say "Works on My Machine"

"Works on my machine" is a claim about one laptop. Here is a short checklist that turns it into a claim about the project. Run it top to bottom once, then keep it next to your README.

  • Replace "works on my machine" with a short checklist for cross-environment compatibility
  • Use single commands to start/stop application and run host checks for Docker, disk space, port usage
  • Pin tool versions, ignore secrets/env files, test resilience by breaking components

More from Monday, 30 November 2026 →