Skip to content

feat: correct default IPs as constants#48

Merged
codeflight1 merged 1 commit into
mainfrom
prefill-all-ips
Jul 13, 2026
Merged

feat: correct default IPs as constants#48
codeflight1 merged 1 commit into
mainfrom
prefill-all-ips

Conversation

@ConnorNeed

Copy link
Copy Markdown
Member

Avoid having random ips all over the place making it more readable and easier to update.

Gives us better defaults in a few places as well

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR centralizes several previously hard-coded IP addresses into a single src/constants.ts module and updates UI components (and a route handler) to use these shared constants, reducing scattered “magic IPs” across the codebase.

Changes:

  • Added src/constants.ts to define shared IP/host defaults (e.g., rover/base AP/base host, tiling server).
  • Updated multiple UI components to use the new constants instead of inline IP strings or runtime env values.
  • Simplified start.sh by removing local IP detection and no longer injecting NEXT_PUBLIC_TILE_SERVER into the web UI container.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
start.sh Removes local IP probing and stops passing tile-server address via env var to the web container.
src/constants.ts Introduces centralized constants for rover/base/AP IPs and tiling server host:port.
src/components/panels/MosaicDashboard.tsx Replaces hard-coded WebRTC signaling IP with ROVER_IP.
src/components/panels/MapView.tsx Switches offline tile URL to use TILING_SERVER constant.
src/components/ContainerList.tsx Sets default launch server base URL using ROVER_IP.
src/components/ContainerCard.tsx Removes env-derived API base logic (but leaves an unused import).
src/components/ConnectionStatusDisplay.tsx Updates default ROS bridge URL to use ROVER_IP.
src/app/dashboard/api/route.ts Replaces hard-coded ping host list with constants.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/components/panels/MapView.tsx Outdated
Comment thread src/components/ConnectionStatusDisplay.tsx Outdated
Comment thread src/constants.ts Outdated
Comment thread src/app/dashboard/api/route.ts Outdated
Comment thread src/components/ContainerCard.tsx
@codeflight1
codeflight1 merged commit 3a2166e into main Jul 13, 2026
1 check passed
@codeflight1
codeflight1 deleted the prefill-all-ips branch July 13, 2026 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants