infra-postgres

โดย clickhouse

ตั้งค่าและจัดการ Postgres โดยใช้ clickhousectl CLI — รัน Postgres ที่ใช้ Docker ในเครื่องสำหรับการพัฒนา และสร้างและดำเนินการจัดการ ClickHouse ที่มีการจัดการ...

npx skills add https://github.com/clickhouse/agent-skills --skill infra-postgres

Postgres with clickhousectl

clickhousectl manages Postgres in two environments:

  • Local — named, Docker-backed Postgres instances on the user's machine, for development.
  • Cloud — managed Postgres services in ClickHouse Cloud (beta), for production: HA, read replicas, point-in-time restore.

This file routes to the right reference. The step-by-step workflows live in ref/local.md and ref/cloud.md — read the one that matches the user's situation before running commands.

Which reference to use

The user wants to...Read
Develop or prototype locally, run tests/CI against Postgres, no cloud account neededref/local.md
Go to production, host a managed Postgres, or use ClickHouse Cloud explicitlyref/cloud.md
Operate an existing cloud service (passwords, TLS, config, replicas, failover, restore)ref/cloud.md
Develop locally now, ship to production laterStart with ref/local.md; it points to ref/cloud.md when it's time to go to prod

If it's genuinely ambiguous (e.g. "set up Postgres for my app"), default to local for development tasks and ask before creating anything in the cloud — cloud services cost money.

Prerequisites (both workflows)

Check that clickhousectl is installed:

which clickhousectl

If not found, install it:

curl -fsSL https://clickhouse.com/cli | sh

This installs to ~/.local/bin/clickhousectl (with a chctl alias). If the command is still not found, suggest export PATH="$HOME/.local/bin:$PATH" or a new terminal.

All commands accept --json for machine-readable output. Exit codes follow gh conventions: 0 success, 1 error, 2 cancelled, 4 auth required.

Related

  • To replicate Postgres data into ClickHouse for analytics, see ClickPipes (clickhousectl cloud clickpipe --help).
  • For ClickHouse itself (local development or ClickHouse Cloud services), use the infra-clickhouse skill.

Skills เพิ่มเติมจาก clickhouse

clickhouse-best-practices
clickhouse
กฎแนวปฏิบัติที่ดีที่สุดของ ClickHouse จำนวน 28 ข้อ จัดตามการออกแบบสคีมา การปรับแต่งคิวรี และกลยุทธ์การนำเข้าข้อมูล ครอบคลุมสามด้านสำคัญ: การเลือกคีย์หลักและชนิดข้อมูล (การตัดสินใจออกแบบที่ไม่สามารถเปลี่ยนแปลงได้), การปรับแต่ง JOIN และคิวรี, และการทำแบทช์อินเสิร์ตพร้อมหลีกเลี่ยงมิวเทชัน รวมถึงกฎ 28 ข้อที่จัดลำดับตามผลกระทบ โดยกฎการออกแบบสคีมาและการปรับแต่งคิวรีถูกทำเครื่องหมายว่าสำคัญมาก (CRITICAL) เนื่องจากกลไกการจัดเก็บแบบคอลัมน์และดัชนีแบบกระจัดกระจายของ ClickHouse มีขั้นตอนการตรวจสอบที่มีโครงสร้างสำหรับ...
official
clickhouse-js-node-coding
clickhouse
Write idiomatic application code with the ClickHouse Node.js client (`@clickhouse/client`). Use this skill whenever a user is *building* against the Node.js…
official
clickhousectl-cloud-deploy
clickhouse
ใช้เมื่อผู้ใช้ต้องการปรับใช้ ClickHouse ไปยังคลาวด์ ไปสู่ระบบผลิต ใช้ ClickHouse Cloud โฮสต์บริการ ClickHouse ที่มีการจัดการ หรือย้ายจากระบบภายในเครื่อง…
official
clickstack-otel-collector
clickhouse
Use when a user wants to wire an OpenTelemetry collector into a Managed ClickStack service on ClickHouse Cloud, either by deploying a new local collector…
official
infra-clickhouse
clickhouse
Sets up and manages ClickHouse using the clickhousectl CLI — installs and runs a local ClickHouse server for development, and creates managed ClickHouse Cloud…
official
clickhouse-best-practices
clickhouse
ต้องใช้เมื่อตรวจสอบสคีมา คิวรี หรือการกำหนดค่าของ ClickHouse ประกอบด้วยกฎ 31 ข้อที่ต้องตรวจสอบก่อนให้คำแนะนำ ควรอ่านเสมอ…
official
setup
clickhouse
แนะนำผู้ใช้ในการตั้งค่าการเชื่อมต่อเซิร์ฟเวอร์ ClickHouse MCP ที่มาพร้อมกับปลั๊กอินนี้ ใช้เมื่อผู้ใช้ติดตั้งปลั๊กอินครั้งแรกหรือพบปัญหา…
official
triage-issues
clickhouse
วิเคราะห์ปัญหา GitHub ทีละรายการ อ่านคำอธิบาย กำหนดป้ายกำกับและลำดับความสำคัญ ค้นคว้าข้อมูลเพิ่มเติม และให้ข้อมูลสรุปสั้น ๆ แต่...
official