Skip to content

Add optional VS Code devcontainer#477

Merged
ljm42 merged 2 commits into
mainfrom
add-devcontainer
May 13, 2026
Merged

Add optional VS Code devcontainer#477
ljm42 merged 2 commits into
mainfrom
add-devcontainer

Conversation

@ljm42
Copy link
Copy Markdown
Member

@ljm42 ljm42 commented May 13, 2026

Before Submitting This PR, Please Ensure You Have Completed The Following:

  1. Are internal links to wiki documents using relative file links?
  2. Are all new documentation files lowercase, with dash separated names (ex. unraid-os.mdx)?
  3. Are all assets (images, etc), located in an assets/ subfolder next to the .md/mdx files?
  4. Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  5. Is the build succeeding?

Summary by CodeRabbit

Release Notes

  • New Features

    • Added VS Code Dev Container support for streamlined local development with pre-configured Node.js environment, package manager, and documentation server.
  • Documentation

    • Added getting started guide for Dev Container setup including Git credentials sharing.
  • Chores

    • Updated build scripts and development configuration.

Review Change Stack

@ljm42 ljm42 requested a review from elibosley May 13, 2026 17:54
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 13, 2026

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
unraid-docs e891d3c Commit Preview URL

Branch Preview URL
May 13 2026, 06:07 PM

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 13, 2026

Warning

Rate limit exceeded

@ljm42 has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 48 minutes and 55 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 5a4afee2-4cc1-47ba-a1d6-140de747ed67

📥 Commits

Reviewing files that changed from the base of the PR and between 9d3e13a and e891d3c.

📒 Files selected for processing (1)
  • scripts/run-docusaurus.mjs
📝 Walkthrough

Walkthrough

The pull request adds VS Code dev container support to the documentation repository. It introduces a Dockerfile and devcontainer.json for a Node.js development environment, creates a Docusaurus process wrapper script with signal handling and configurable host/port binding, updates npm scripts to use the wrapper, and documents the container setup in the README.

Changes

VS Code Dev Container and Docusaurus Wrapper

Layer / File(s) Summary
Dev Container Infrastructure
.devcontainer/Dockerfile, .devcontainer/devcontainer.json
Container image installs Node.js, CLI utilities (git, curl, wget, jq, actionlint), enables corepack and pnpm, configures vscode user with sudo access, and creates /workspaces/docs. DevContainer config specifies Dockerfile build, environment variables for Docusaurus binding, GitHub credential volume mount, post-create/start commands for corepack and frozen pnpm install, port forwarding (3000, 3001), and VS Code extensions/TypeScript SDK settings.
Docusaurus Process Wrapper and Script Integration
scripts/run-docusaurus.mjs, package.json
New wrapper script validates command input (start/serve), resolves DOCUSAURUS_BIND_HOST and DOCUSAURUS_PORT from environment with command-specific defaults, spawns docusaurus via pnpm exec, and installs handlers for SIGINT/SIGTERM signal forwarding and child exit code propagation. Package.json start, serve, and clear scripts are routed through the wrapper.
Documentation and Build Configuration
.gitignore, README.md
.gitignore excludes .pnpm-store/. README documents VS Code Dev Container setup, including prerequisites (Docker Desktop, Dev Containers extension), what the container provides (Node from .nvmrc, Corepack/pnpm, Docusaurus dev server on port 3001, included CLI tools), and how to share Git credentials and persist GitHub CLI authentication via named Docker volume.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Poem

🐰 A container springs forth with Node and care,
With pnpm dancing, signal handlers fair,
Port 3001 blooms for docs to see,
Dev environment wrapped, now safe and free! 🌱

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description only contains the template checklist with no actual description of the changes made. It lacks details about what was added and why. Add a meaningful description explaining the devcontainer setup, its purpose, and how to use it. The template checklist alone is insufficient without substantive PR context.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately reflects the main change: adding a VS Code devcontainer setup with Dockerfile, devcontainer.json, and supporting scripts.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch add-devcontainer

Warning

Review ran into problems

🔥 Problems

Git: Failed to clone repository. Please run the @coderabbitai full review command to re-trigger a full review. If the issue persists, set path_filters to include or exclude specific files.


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 and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

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 `@scripts/run-docusaurus.mjs`:
- Around line 5-31: The script only uses process.argv[2] (commandName) and
builds a fixed args array for spawn, so any extra flags after the command (e.g.
--no-open) are dropped; update the spawn invocation that constructs the args for
the docusaurus call (the array passed to spawn in the variable child) to append
process.argv.slice(3) (the extra CLI args) to
["exec","docusaurus",commandName,"--host",host,"--port",port] so all
user-provided flags are forwarded; ensure you still use the existing
commandName, host and port variables and keep stdio: "inherit".
🪄 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: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 989cefa9-9a37-4d27-a1b9-5c42381dcdc1

📥 Commits

Reviewing files that changed from the base of the PR and between 000c2b9 and 9d3e13a.

📒 Files selected for processing (6)
  • .devcontainer/Dockerfile
  • .devcontainer/devcontainer.json
  • .gitignore
  • README.md
  • package.json
  • scripts/run-docusaurus.mjs

Comment thread scripts/run-docusaurus.mjs
@ljm42 ljm42 merged commit bcd7692 into main May 13, 2026
4 checks passed
@ljm42 ljm42 deleted the add-devcontainer branch May 13, 2026 18:11
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.

1 participant