feat(1463): bootstrap-node.sh — idempotent node bootstrap, mesh-bind validation, Jetson profiles - #1626
Conversation
|
Warning Review limit reached
More reviews will be available in 59 minutes and 50 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughTwo new Jetson Orin NX 16GB node configuration profiles are added for edge-inference deployment units. Each profile specifies arm64 hardware details, GPU compute capability, memory/storage capacity, service assignments, Tailscale role mapping, and Docker/NVIDIA runtime requirements. ChangesJetson Orin Node Profiles
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 11ff33c9d5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ok "pmoves_bus network already exists" | ||
| else | ||
| info "Creating pmoves_bus network (172.30.3.0/24)..." | ||
| if docker network create --driver bridge --subnet 172.30.3.0/24 pmoves_bus; then |
There was a problem hiding this comment.
Create pmoves_bus as an internal network
The network creation path omits --internal, so a first-time bootstrap creates pmoves_bus with external routing enabled even though the compose definitions expect internal: true for this tier. If this script runs before Compose, Docker reuses that weaker network and bus-attached containers can unexpectedly egress, violating the intended isolation/hardening model for messaging traffic. Include --internal (and matching gateway settings) when creating pmoves_bus.
Useful? React with 👍 / 👎.
| if command -v nats >/dev/null 2>&1; then | ||
| info "Publishing mesh.node.online.v1..." | ||
| dim "payload: $PAYLOAD" | ||
| if echo "$PAYLOAD" | nats pub --server "${NATS_URL:-nats://localhost:4222}" mesh.node.online.v1; then |
There was a problem hiding this comment.
Publish mesh online announce on the canonical subject
This step publishes mesh.node.online.v1, but the repo’s subject registry and agent subscriptions are wired to mesh.node.announce.v1; there are no in-repo consumers for the new subject. In the common case where operators rerun mesh-bind.sh to announce readiness, discovery listeners won’t receive this event even though the script reports success. Publish on mesh.node.announce.v1 (or add full contract + consumer support for mesh.node.online.v1).
Useful? React with 👍 / 👎.
| if docker network inspect pmoves_bus >/dev/null 2>&1; then | ||
| ok "pmoves_bus network already exists" |
There was a problem hiding this comment.
Verify existing pmoves_bus CIDR before declaring success
When pmoves_bus already exists, the script immediately marks Step 3 as OK without validating the subnet. If the host has a drifted or manually recreated network, bootstrap still passes while downstream mesh assumptions (172.30.3.0/24) can break connectivity and troubleshooting becomes misleading. Mirror the explicit CIDR validation used elsewhere before treating an existing network as healthy.
Useful? React with 👍 / 👎.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
11ff33c to
3d4cfd4
Compare
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@pmoves/config/profiles/jetson-orin-1.yaml`:
- Around line 14-19: Replace the singular hardware.gpu mapping with the
canonical hardware.gpus list shape so GPU-aware consumers find the metadata:
rename the key `gpu` to `gpus` and wrap the existing object (keys `type`,
`model`, `cuda_cores`, `compute_capability`, `memory_gb`) as a single-item YAML
list under `gpus`, preserving all values and comments.
In `@pmoves/config/profiles/jetson-orin-2.yaml`:
- Around line 14-19: Replace the singular gpu mapping with a hardware.gpus list
to match the canonical profile shape: rename the top-level "gpu" block to "gpus"
under "hardware" and convert its fields (type, model, cuda_cores,
compute_capability, memory_gb) into a single-item list element so the profile
uses hardware.gpus: - ensure the list contains the same key names (type, model,
cuda_cores, compute_capability, memory_gb) and preserve values (e.g., "Jetson
Orin NX Ampere (integrated)", 1024, "8.7", 16) so downstream profile generation
expects a list rather than a singular gpu object.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 336a8096-b6a2-46fd-99e8-54c584ae03f6
📒 Files selected for processing (2)
pmoves/config/profiles/jetson-orin-1.yamlpmoves/config/profiles/jetson-orin-2.yaml
…t, gpus list schema Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Summary
Node bootstrap infrastructure for issue #1463 (complements #1614 runner registration):
PR-A — bootstrap-node.sh (3 commits):
99296a68c— feat: bootstrap-node.sh — idempotent node bootstrap scriptfa910d2fc— fix: nats server ping + complete json-to-profile hint17173a875— fix: idempotency + arg validation + quality fixesPR-B — mesh-bind.sh (2 commits):
65d22bb63— feat: mesh-bind.sh — pmoves_bus validation + mesh online announce337ef7409— fix: guard trailing --node-id / --peer against set -e abortPR-C — Jetson profiles (1 commit):
11ff33c9d— feat: add Jetson Orin NX 16GB fleet profiles (orin-1, orin-2)Related:
feat/1463-runner-registration(#1614) — runner setup side of the same issue.Test plan
bash bootstrap-node.sh --node-id orin-1 --peer pmoves-sparkruns idempotently (safe to re-run)bash mesh-bind.shvalidates NATS bus connectivity and announces mesh onlineorin-1/orin-2profiles exist in fleet profile catalog🤖 Generated with Claude Code
Summary by CodeRabbit