Repository navigation
Add setting-up-local-cluster skill for local development setup - #7
Conversation
Guides downloading and starting a local CockroachDB cluster using the official binary. Defaults to a 3-node cluster to exercise replication, range distribution, leaseholder balancing, and survival goals. Includes single-node option, air-gapped environment support, and MCP Toolbox environment variable configuration.
There was a problem hiding this comment.
Pull request overview
Adds a new onboarding skill that documents how to download and run a local CockroachDB cluster (defaulting to a 3-node setup) for development using the official binary.
Changes:
- Introduces a new
setting-up-local-clusterskill with binary download instructions and artifact naming patterns. - Documents commands for starting a 3-node cluster (plus a single-node alternative) and verifying connectivity/health.
- Adds guidance for air-gapped environments, MCP Toolbox env vars, and basic stop/data-destruction steps.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ### Installation | ||
|
|
||
| ```bash | ||
| # Example: macOS Apple Silicon, v25.4.9 | ||
| curl -fsSL https://binaries.cockroachdb.com/cockroach-v25.4.9.darwin-11.0-arm64.tgz | tar xz | ||
| mkdir -p ~/.cockroachdb/bin | ||
| cp cockroach-v25.4.9.darwin-11.0-arm64/cockroach ~/.cockroachdb/bin/ | ||
| export PATH="$HOME/.cockroachdb/bin:$PATH" | ||
| ``` |
There was a problem hiding this comment.
The prerequisites and download table mention Windows, but the Installation section only shows a macOS curl | tar example and doesn’t include Windows (PowerShell) download/extract steps or PATH guidance. Add a Windows-specific snippet (or explicitly scope the skill to WSL/macOS/Linux) so the Windows claim is actionable.
| ## Step 1: Detect Platform and Download | ||
|
|
||
| Detect the OS and architecture, then download the appropriate binary. | ||
|
|
There was a problem hiding this comment.
The PR description calls out “platform detection”, and this section says “Detect the OS and architecture”, but no concrete detection commands or decision logic are provided. Either add minimal uname/arch/PowerShell detection steps (and how to map them to the filename patterns) or reword this section to indicate that the user must select the correct artifact manually.
| kill $(cat ~/.cockroachdb/data/node1/cockroach.pid) 2>/dev/null | ||
| kill $(cat ~/.cockroachdb/data/node2/cockroach.pid) 2>/dev/null | ||
| kill $(cat ~/.cockroachdb/data/node3/cockroach.pid) 2>/dev/null |
There was a problem hiding this comment.
The stop commands will still emit errors from cat if a PID file doesn’t exist (stderr redirection only applies to kill). Consider guarding with a file existence check or redirecting cat stderr as well, so “stop” is quiet/idempotent when nodes aren’t running.
| kill $(cat ~/.cockroachdb/data/node1/cockroach.pid) 2>/dev/null | |
| kill $(cat ~/.cockroachdb/data/node2/cockroach.pid) 2>/dev/null | |
| kill $(cat ~/.cockroachdb/data/node3/cockroach.pid) 2>/dev/null | |
| [ -f ~/.cockroachdb/data/node1/cockroach.pid ] && kill "$(cat ~/.cockroachdb/data/node1/cockroach.pid)" 2>/dev/null | |
| [ -f ~/.cockroachdb/data/node2/cockroach.pid ] && kill "$(cat ~/.cockroachdb/data/node2/cockroach.pid)" 2>/dev/null | |
| [ -f ~/.cockroachdb/data/node3/cockroach.pid ] && kill "$(cat ~/.cockroachdb/data/node3/cockroach.pid)" 2>/dev/null |
| name: setting-up-local-cluster | ||
| description: Downloads and starts a local CockroachDB cluster for development using the official binary. Use when a developer needs a local CockroachDB instance, when no cluster is available, or when setting up a new development environment. | ||
| --- | ||
|
|
||
| # Setting Up a Local CockroachDB Cluster |
There was a problem hiding this comment.
scripts/validate-spec.py emits a naming warning when the skill name doesn’t end with ing (and doesn’t match one of its allowed gerund prefixes). setting-up-local-cluster will trigger that warning; consider renaming to an *-ing form (and matching the directory name) if you want validation to be clean even under --strict.
| name: setting-up-local-cluster | |
| description: Downloads and starts a local CockroachDB cluster for development using the official binary. Use when a developer needs a local CockroachDB instance, when no cluster is available, or when setting up a new development environment. | |
| --- | |
| # Setting Up a Local CockroachDB Cluster | |
| name: local-cockroachdb-cluster-provisioning | |
| description: Downloads and starts a local CockroachDB cluster for development using the official binary. Use when a developer needs a local CockroachDB instance, when no cluster is available, or when setting up a new development environment. | |
| --- | |
| # Local CockroachDB Cluster Provisioning |
| Replace `{VERSION}` with the desired release (e.g., `25.4.9`). See [CockroachDB Releases](https://www.cockroachlabs.com/docs/releases/) for the latest GA version. | ||
|
|
||
| ### Installation | ||
|
|
||
| ```bash | ||
| # Example: macOS Apple Silicon, v25.4.9 | ||
| curl -fsSL https://binaries.cockroachdb.com/cockroach-v25.4.9.darwin-11.0-arm64.tgz | tar xz | ||
| mkdir -p ~/.cockroachdb/bin | ||
| cp cockroach-v25.4.9.darwin-11.0-arm64/cockroach ~/.cockroachdb/bin/ |
There was a problem hiding this comment.
The skill includes a specific CockroachDB version (e.g., 25.4.9) and refers to “the latest GA version”. The repo PR template explicitly calls out avoiding time-sensitive information (including version numbers), so this should be rewritten to use placeholders (e.g., {VERSION}) throughout the example commands and avoid wording that implies a moving target.
| Replace `{VERSION}` with the desired release (e.g., `25.4.9`). See [CockroachDB Releases](https://www.cockroachlabs.com/docs/releases/) for the latest GA version. | |
| ### Installation | |
| ```bash | |
| # Example: macOS Apple Silicon, v25.4.9 | |
| curl -fsSL https://binaries.cockroachdb.com/cockroach-v25.4.9.darwin-11.0-arm64.tgz | tar xz | |
| mkdir -p ~/.cockroachdb/bin | |
| cp cockroach-v25.4.9.darwin-11.0-arm64/cockroach ~/.cockroachdb/bin/ | |
| Replace `{VERSION}` with the desired CockroachDB release. See [CockroachDB Releases](https://www.cockroachlabs.com/docs/releases/) to choose a release. | |
| ### Installation | |
| ```bash | |
| # Example: macOS Apple Silicon | |
| curl -fsSL https://binaries.cockroachdb.com/cockroach-v{VERSION}.darwin-11.0-arm64.tgz | tar xz | |
| mkdir -p ~/.cockroachdb/bin | |
| cp cockroach-v{VERSION}.darwin-11.0-arm64/cockroach ~/.cockroachdb/bin/ |
Adds a new skill under
onboarding-and-migrations/setting-up-local-clusterthat guides downloading and starting a local CockroachDB cluster using the official binary.Key points:
What does this PR do?
Related Issue
Closes #
Type of Change
Skill Compliance Checklist
name,description)references/for detailed content)scripts/,references/,assets/subdirs)python scripts/validate-spec.py skills/Documentation Updates
Testing
Manual testing:
Automated testing:
python scripts/validate-spec.py skills/Additional Context
Reviewer Notes
By submitting this PR, I confirm: