We value your privacy

This site uses cookies to improve your browsing experience, analyze site traffic, and show personalized content. See our Privacy Policy.

  1. MooseStack
  2. Configuration
  3. ClickHouse Configuration

ClickHouse Configuration

Configure the OLAP database connection.

Security Warning

NEVER put production credentials in moose.config.toml. For production environments or when connecting to external infrastructure, ALWAYS use environment variables and/or secrets to securely inject credentials.

moose.config.toml
[clickhouse_config]# Database name (Default: "local")db_name = "local"# ClickHouse user (Default: "panda")user = "panda"# ClickHouse password (Default: "pandapass")password = "pandapass"# Whether to use SSL for connection (Default: false)use_ssl = false# ClickHouse host (Default: "localhost")host = "localhost"# ClickHouse HTTP port (Default: 18123)host_port = 18123# ClickHouse native protocol port (Default: 9000)native_port = 9000
KeyEnv VariableDefaultDescription
db_nameMOOSE_CLICKHOUSE_CONFIG__DB_NAME"local"The database name to use.
userMOOSE_CLICKHOUSE_CONFIG__USER"panda"Database user.
passwordMOOSE_CLICKHOUSE_CONFIG__PASSWORD"pandapass"SECRET. Use env var in prod.
use_sslMOOSE_CLICKHOUSE_CONFIG__USE_SSLfalseEnable SSL connection.
hostMOOSE_CLICKHOUSE_CONFIG__HOST"localhost"ClickHouse server host.
host_portMOOSE_CLICKHOUSE_CONFIG__HOST_PORT18123HTTP interface port (and Docker bind port in dev).
native_portMOOSE_CLICKHOUSE_CONFIG__NATIVE_PORT9000Native TCP protocol port.
FiveonefourFiveonefour
Fiveonefour Docs
MooseStackHostingTemplatesGuides
Release Notes
Source531
  • Overview
Build a New App
  • 5 Minute Quickstart
  • Browse Templates
  • Existing ClickHouse
Add to Existing App
  • Next.js
  • Fastify
Fundamentals
  • Moose Runtime
  • MooseDev MCP
  • Language Server
  • Data Modeling
Moose Modules
  • Moose OLAP
  • Moose Streaming
  • Moose Workflows
  • Moose APIs & Web Apps
Deployment & Lifecycle
  • Moose Dev
  • Moose Migrate
  • Moose Deploy
Reference
  • API Reference
  • Data Types
  • Table Engines
  • CLI
  • Configuration
    • Core Settings
    • Project Settings
    • TypeScript
    • Telemetry
    • Git
    • Features
    • Migrations
    • Docker
    • Infrastructure
    • ClickHouse
    • Redpanda
    • Redis
    • Temporal
    • HTTP Server
    • State Storage
    • Security
    • JWT
    • Admin API
    • Development
    • Dev Environment
  • Observability Metrics
  • Help
  • Release Notes
Contribution
  • Documentation
  • Framework