Index of every page on this site: llms.txt
All skills
jeremylongshore avatar

/clickhouse-local-dev-loop

@0d57af8
Run it yourself

Run ClickHouse locally with Docker, configure test fixtures, and iterate fast. Use when setting up a local ClickHouse dev environment, writing integration tests against ClickHouse, or running ClickHouse in Docker Compose for local work. Trigger with "clickhouse local dev", "clickhouse docker", "clickhouse dev environment", "run clickhouse locally", "clickhouse docker compose".

Use this Skill: https://skilld.dev/gh/jeremylongshore/tons-of-skills-marketplace/clickhouse-local-dev-loop

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesexamples.md

≈505 tokens on demand. Your agent reads this file only when SKILL.md points to it.

ClickHouse Local Dev Loop — Examples

Concrete, copy-pasteable examples for the everyday dev loop: bringing the container up, seeding, querying, and inspecting server state.

Example 1: Cold start to first query

# Bring the stack up and wait for readiness
docker compose up -d
curl http://localhost:8123/ping        # → "Ok.\n"

# Seed 1000 synthetic events
npm run db:seed                          # runs tsx scripts/seed.ts

# Confirm the rows landed
curl 'http://localhost:8123/?query=SELECT+count()+FROM+app.events'
# → 1000

Example 2: Interactive SQL shell

# Open a clickhouse-client session inside the container
docker exec -it <container> clickhouse-client --password dev_password

# Or via the package script
npm run db:shell
-- Once inside the shell
SELECT event_type, count() AS n
FROM app.events
GROUP BY event_type
ORDER BY n DESC;

Example 3: Run a query from the host over HTTP

# URL-encode the query and hit the HTTP interface
curl 'http://localhost:8123/?query=SELECT+event_type,count()+FROM+app.events+GROUP+BY+event_type+FORMAT+PrettyCompact'

Example 4: Inspect server state

# Currently running queries
curl 'http://localhost:8123/?query=SELECT+*+FROM+system.processes+FORMAT+PrettyCompact'

# In-flight background merges
curl 'http://localhost:8123/?query=SELECT+*+FROM+system.merges+FORMAT+PrettyCompact'

Example 5: Reset the environment between test runs

# Drop the volume and recreate a clean container + schema
npm run db:reset          # docker compose down -v && docker compose up -d
npm run db:seed           # re-seed fresh data

Example 6: A passing integration test run

npm test
# ✓ tests/events.test.ts (1)
#   ✓ ClickHouse events (1)
#     ✓ inserts and queries events

The beforeEach hook in tests/setup.ts TRUNCATEs app.events before every test, so each case starts from an empty table and the assertion expect(Number(row.cnt)).toBe(2) is deterministic.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    The skill provides a standard setup for a local ClickHouse development environment using Docker and Node.js. It follows security best practices by recommending environment variable overrides for credentials and using local-only network communication.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 0d57af8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 4 months ago
What it can do
Reads files Edits files Runs commands
version
1.7.0
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
[
  "saas",
  "database",
  "analytics",
  "clickhouse",
  "olap"
]
All 5 allowed tools
ReadWriteEditBash(docker:*)Bash(docker-compose:*)
Other metadata
compatibility
Designed for Claude Code

README badge

README badge for jeremylongshore/tons-of-skills-marketplace/clickhouse-local-dev-loop