VooDisss f3c54df283 fix(server): show sane remote URLs for 0.0.0.0 binds (#262)
Closes #261

## Summary

- improve startup remote URL selection when the server binds to
`0.0.0.0`
- print additional reachable remote URLs instead of advertising only the
first external address
- add targeted tests for address ordering and advertisability behavior

## Problem

When CodeNomad was started with `--host 0.0.0.0`, the CLI chose the
first external IPv4 address it discovered and displayed only that one as
the remote URL.

On Windows machines with WSL, Hyper-V, Docker, or other virtual
adapters, that often surfaced a virtual `172.x.x.x` address even though
a more useful LAN address such as `192.168.x.x` was also reachable and
usable from other devices.

That made remote access look broken or confusing even though the server
itself was accessible.

## What changed

- reuse the resolved network-address list for both:
  - primary remote URL selection
  - startup logging of additional reachable URLs
- choose the primary remote URL from the **advertisable** external
addresses instead of any external address
- print `Other Accessible URLs` when multiple useful remote URLs are
available
- avoid hard-coding a preference like `192.168 > 10 > 172`
- suppress link-local `169.254.*` addresses from user-facing advertised
URLs
- add tests covering:
  - stable ordering across RFC1918 address ranges
  - link-local addresses being non-advertisable
  - link-local-first discovery not stealing the primary LAN URL

## Why this approach

This keeps address derivation in the network-address resolver layer and
limits `index.ts` to startup wiring and presentation.

It also fixes the misleading terminal output without redesigning binding
behavior, TLS behavior, or the server API contract.

## Validation

- `npm run typecheck --workspace @neuralnomads/codenomad`
- `npx tsx --test
'.\\src\\server\\__tests__\\network-addresses.test.ts'`

## Notes

- this change is intentionally focused on selection and presentation of
reachable addresses
- it does not attempt a broader virtual-adapter classification policy
beyond suppressing clearly low-value link-local addresses in user-facing
output

---------

Co-authored-by: Shantur Rathore <i@shantur.com>
2026-04-01 22:12:28 +01:00
2026-01-24 19:21:56 +00:00
2025-12-02 19:23:05 +00:00
2025-11-21 21:59:58 +00:00
2026-02-17 18:47:21 +00:00
2026-02-02 11:22:49 +00:00
2026-03-31 20:15:25 +01:00
2026-03-31 20:15:25 +01:00
2026-02-17 18:43:02 +00:00

CodeNomad

A fast, multi-instance workspace for running OpenCode sessions.

CodeNomad is built for people who live inside OpenCode for hours on end and need a cockpit, not a kiosk. It delivers a premium, low-latency workspace that favors speed, clarity, and direct control.

Multi-instance workspace Manage multiple OpenCode sessions side-by-side.

📸 More Screenshots

Command palette overlay Global command palette for keyboard-first control.

Image Previews Rich media previews for images and assets.

Browser Support Browser support via CodeNomad Server.

Getting Started

Choose the way that fits your workflow:

The best experience. A native application (Electron-based) with global shortcuts, deeper system integration, and a dedicated window.

  • Download: Grab the latest installer for macOS, Windows, or Linux from the Releases Page.
  • Run: Install and launch like any other app.

🦀 Tauri App (Experimental)

We are also working on a lightweight, high-performance version built with Tauri. It is currently in active development.

  • Download: Experimental builds are available on the Releases Page.
  • Source: Check out packages/tauri-app if you're interested in contributing.

💻 CodeNomad Server

Run CodeNomad as a local server and access it via your web browser. Perfect for remote development (SSH/VPN) or running as a service.

npx @neuralnomads/codenomad --launch

Full server/CLI documentation (flags + env vars, TLS, auth, remote access):

To see all available options:

npx @neuralnomads/codenomad --help

🧪 Dev Releases

Bleeding-edge builds are published as GitHub pre-releases and are generated automatically from the dev branch.

npx @neuralnomads/codenomad-dev --launch

Highlights

  • Multi-Instance: Juggle several OpenCode sessions side-by-side with tabs.
  • Long-Session Native: Scroll through massive transcripts without hitches.
  • Command Palette: A single global palette to jump tabs, launch tools, and control everything.
  • Deep Task Awareness: Monitor background tasks and child sessions without losing flow.

Requirements

  • OpenCode CLI: Must be installed and available in your PATH.
  • Node.js 18+: Required if running the CLI server or building from source.

Troubleshooting

macOS says the app is damaged

If macOS reports that "CodeNomad.app is damaged and can't be opened," Gatekeeper flagged the download because the app is not yet notarized. You can clear the quarantine flag after moving CodeNomad into /Applications:

xattr -l /Applications/CodeNomad.app
xattr -dr com.apple.quarantine /Applications/CodeNomad.app

After removing the quarantine attribute, launch the app normally. On Intel Macs you may also need to approve CodeNomad from System Settings → Privacy & Security the first time you run it.

Linux (Wayland + NVIDIA): Tauri AppImage closes immediately

On some Wayland compositor + NVIDIA driver setups, WebKitGTK can fail to initialize its DMA-BUF/GBM path and the Tauri build may exit right away.

Try running with one of these environment variables:

# Most reliable workaround (can reduce rendering performance)
WEBKIT_DISABLE_DMABUF_RENDERER=1 codenomad

# Alternative for some Wayland setups
__NV_DISABLE_EXPLICIT_SYNC=1 codenomad

If you're running the Tauri AppImage and want the workaround applied every time, create a tiny wrapper script on your PATH:

#!/bin/bash
export WEBKIT_DISABLE_DMABUF_RENDERER=1
exec ~/.local/share/bauh/appimage/installed/codenomad/CodeNomad-Tauri-0.4.0-linux-x64.AppImage "$@"

Upstream tracking: https://github.com/tauri-apps/tauri/issues/10702

Architecture & Development

CodeNomad is a monorepo split into specialized packages. If you want to contribute or build from source, check out the individual package documentation:

Package Description
packages/electron-app The native desktop application shell. Wraps the UI and Server.
packages/server The core logic and CLI. Manages workspaces, proxies OpenCode, and serves the API.
packages/ui The SolidJS-based frontend. Fast, reactive, and beautiful.

Quick Build

To build the Desktop App from source:

  1. Clone the repo.
  2. Run npm install (requires pnpm or npm 7+ for workspaces).
  3. Run npm run build --workspace @neuralnomads/codenomad-electron-app.

Star History Chart

Description
CodeNomad: The command center that puts AI coding on steroids.
Readme MIT 109 MiB
Languages
TypeScript 88.4%
CSS 6.7%
Rust 3.2%
JavaScript 1.5%
HTML 0.2%