Skip to content

update nym-node-cli#6964

Merged
serinko merged 6 commits into
developfrom
serinko/node-cli-debug
Jul 21, 2026
Merged

update nym-node-cli#6964
serinko merged 6 commits into
developfrom
serinko/node-cli-debug

Conversation

@serinko

@serinko serinko commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Maintenance of nym-node-cli and debugging some logic issues to make the tool work properly


This change is Reviewable

Summary by CodeRabbit

  • New Features
    • Added role-aware node setup to determine required components for tunneling, firewall/ufw rules, WireGuard/exit policies, and QUIC deployment.
  • Bug Fixes
    • Improved prerequisites installation reliability with non-interactive apt, recovery from interrupted installs, and safer dependency installation.
    • Enhanced setup script downloading with retries and basic content validation.
  • Improvements
    • Updated nginx reverse-proxy + WSS deployment to better manage certificates and only enable HTTPS/WSS when valid.
    • Made time synchronization provisioning adaptive across available services.
    • Refreshed operator documentation command example and updated the node setup tool to v1.3.0.

@serinko serinko added this to the Independent Release milestone Jul 21, 2026
@serinko
serinko requested review from merve64 and mfahampshire July 21, 2026 11:08
@serinko serinko self-assigned this Jul 21, 2026
@vercel

vercel Bot commented Jul 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs-nextra Ready Ready Preview, Comment Jul 21, 2026 1:09pm
nym-explorer-v2 Ready Ready Preview, Comment Jul 21, 2026 1:09pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
nym-node-status Ignored Ignored Preview Jul 21, 2026 1:09pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 0dda7101-cb39-40c9-9aa1-6926032cb057

📥 Commits

Reviewing files that changed from the base of the PR and between 5ca1f6a and 2054595.

📒 Files selected for processing (1)
  • documentation/docs/pages/operators/tools.mdx
🚧 Files skipped from review as they are similar to previous changes (1)
  • documentation/docs/pages/operators/tools.mdx

📝 Walkthrough

Walkthrough

The node setup flow now derives WireGuard-aware installation capabilities, retrieves scripts with retrying HTTPS requests, configures prerequisites and UFW through separate stages, and conditionally provisions nginx, HTTPS, WSS, tunnel, WireGuard, and QUIC components.

Changes

Node setup installation

Layer / File(s) Summary
Prerequisite provisioning
scripts/nym-node-setup/nym-node-prereqs-install.sh
Package-manager recovery, non-interactive installation, optional dependency handling, adaptive time synchronization, and CLI-owned firewall configuration were added.
Mode capability resolution
scripts/nym-node-setup/nym-node-cli.py
WireGuard-aware capabilities now control script retrieval and installation behavior; script downloads use retrying urllib requests.
Mode-specific installation orchestration
scripts/nym-node-setup/nym-node-cli.py
UFW rules and nginx, tunnel, WireGuard, and QUIC setup steps are selected using derived node capabilities.
HTTPS and WSS provisioning
scripts/nym-node-setup/setup-nginx-proxy-wss.sh
Nginx configuration, certificate issuance, HTTPS redirection, reverse proxying, and conditional WSS enablement were reorganized.
CLI installation documentation
documentation/docs/pages/operators/tools.mdx
The installation example now uses multiline arguments and revised sample values.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant NodeSetupCLI
  participant PrerequisitesScript
  participant NginxWssScript
  participant Certbot
  participant Nginx
  NodeSetupCLI->>PrerequisitesScript: install prerequisites
  PrerequisitesScript-->>NodeSetupCLI: dependencies ready
  NodeSetupCLI->>NginxWssScript: run conditional nginx and WSS setup
  NginxWssScript->>Certbot: request certificate
  Certbot-->>NginxWssScript: return certificate status
  NginxWssScript->>Nginx: enable HTTPS and WSS when certificate exists
  NginxWssScript-->>NodeSetupCLI: report HTTP, HTTPS, and WSS status
Loading

Suggested reviewers: mfahampshire, benedettadavico

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title names the affected tool, but it is too generic to convey the main changes or why they matter. Use a more specific title such as "Refine nym-node-cli setup flow and nginx/WireGuard handling".
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch serinko/node-cli-debug

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install timed out. The project may have too many dependencies for the sandbox.


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

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 `@scripts/nym-node-setup/nym-node-prereqs-install.sh`:
- Around line 8-29: Enable fail-fast behavior near the start of
nym-node-prereqs-install.sh, before the apt update, upgrade, and core dependency
installation commands, so failures in those hard requirements terminate the
script. Preserve the existing explicit || true and conditional guards for
intentional recovery and optional fallbacks.

In `@scripts/nym-node-setup/setup-nginx-proxy-wss.sh`:
- Around line 108-127: Update the HTTP vhost generation around HTTP_CONF so the
location / behavior is chosen after checking whether the certificate exists:
redirect to HTTPS only when the certificate is available, otherwise serve the
configured WEBROOT with index.html over plain HTTP. Keep the ACME challenge
location reachable in both cases and ensure the certificate check occurs before
writing the vhost.
🪄 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: defaults

Review profile: CHILL

Plan: Pro

Run ID: eb47eb42-fbaf-4982-88d7-c00f43ab1010

📥 Commits

Reviewing files that changed from the base of the PR and between 897e878 and 479d269.

📒 Files selected for processing (3)
  • scripts/nym-node-setup/nym-node-cli.py
  • scripts/nym-node-setup/nym-node-prereqs-install.sh
  • scripts/nym-node-setup/setup-nginx-proxy-wss.sh

Comment thread scripts/nym-node-setup/nym-node-prereqs-install.sh
Comment thread scripts/nym-node-setup/setup-nginx-proxy-wss.sh

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1

🤖 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 `@documentation/docs/pages/operators/tools.mdx`:
- Around line 81-84: Update the command example around nym-node-cli.py so the
optional --dev argument remains part of a valid shell command. Move the
development comment outside the continued command, or add a separate complete
command example that includes --dev, ensuring uncommenting it passes the option
to nym-node-cli.py rather than executing it independently.
🪄 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: defaults

Review profile: CHILL

Plan: Pro

Run ID: f4d26880-0375-4ac9-9e77-f92c0193c5e8

📥 Commits

Reviewing files that changed from the base of the PR and between 479d269 and 5ca1f6a.

📒 Files selected for processing (3)
  • documentation/docs/pages/operators/tools.mdx
  • scripts/nym-node-setup/nym-node-prereqs-install.sh
  • scripts/nym-node-setup/setup-nginx-proxy-wss.sh
🚧 Files skipped from review as they are similar to previous changes (2)
  • scripts/nym-node-setup/nym-node-prereqs-install.sh
  • scripts/nym-node-setup/setup-nginx-proxy-wss.sh

Comment thread documentation/docs/pages/operators/tools.mdx Outdated
@serinko
serinko merged commit 89a5f65 into develop Jul 21, 2026
10 checks passed
@serinko
serinko deleted the serinko/node-cli-debug branch July 21, 2026 13:11
@serinko
serinko restored the serinko/node-cli-debug branch July 21, 2026 13:16
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.

2 participants