Skip to main content

Installation & Configuration

1. Overview

CSGHub provides a one-click Docker deployment method via Docker Compose. This allows you to quickly launch an All-in-One service stack without complex dependency configurations.

Target Use Cases:

  • Quick Experience: Explore all basic CSGHub features and complete functional verification.
  • Development/Testing: Rapidly deploy environments to reduce setup costs.
  • Small/Medium Enterprise Production: Meet daily operational requirements for smaller teams.

2. Advantages

  • Simplified Management: Orchestrate all service dependencies through Docker Compose; no need to deploy components individually.
  • Rapid Deployment: Start the complete CSGHub stack with a single command, significantly increasing deployment efficiency.
  • Flexible Scaling: Supports horizontal scaling and multi-node deployment to adjust to business needs.
  • Production Ready: Optimized and adapted for small to medium enterprise production environments to ensure stability.

3. Startup Modes

CSGHub Docker deployment supports two operation modes. Choose the one that fits your requirements:

ModeFunctional ScopeDependency Environment
Basic FunctionsAll core features except Evaluation, Inference, Fine-tuning, Spaces, and MCP.Only Docker & Docker Compose; no Kubernetes cluster required.
Full FunctionsAll features of CE/EE versions, including advanced model-related operations.Requires a pre-configured Kubernetes cluster.

⚠️ Notes:

  • When accessing via IP address, MCP functionality is limited (Domain usage is strongly recommended).
  • Docker deployment does not include Dataflow or Runner services; these must be deployed via Helm Charts.

4. Quick Start

Although Docker can be started as a single container, using Docker Compose is recommended for better configuration management.

4.1 Create docker-compose.yaml

Create the configuration file and copy the content below (adjust ports and mount paths as needed):

services:
csghub:
container_name: csghub-omnibus
# `latest` defaults to the latest release version of EE.
image: [opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsghq/omnibus-csghub:latest](https://opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsghq/omnibus-csghub:latest)
restart: always

environment:
CSGHUB_OMNIBUS_CONFIG: |
csghub:
external_url: "[http://csghub.example.com](http://csghub.example.com)"

ports:
- '80:80'
- '2222:2222'
- '8000:8000'
- '9000:9000'

volumes:
- ./csghub/etc:/etc/csghub
- ./csghub/logs:/var/log/csghub
- ./csghub/data:/var/opt/csghub
- ./csghub/.kube:/etc/csghub/.kube:ro

healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/healthz"]
interval: 30s
timeout: 10s
retries: 3
start_period: 30s

deploy:
resources:
limits:
cpus: 4
memory: 8G

networks:
default:
name: csghub_network

References:

  • Tags: Obtain available CE/EE version tags to specify image versions.
  • Configurations: Get more detailed configuration item references.
  • Port Mapping: Adjust port settings if the default ports are in use.

4.2 Start Services

Run the following command in the directory containing your docker-compose.yaml:

docker compose up -d && docker compose ps

4.3 Verify Service Status

Run the following command to ensure all internal CSGHub services are running correctly:

docker exec -it csghub-omnibus csghub-ctl status

4.4 Instance Access

  • Access URL: The external_url defined in your config.

  • Default Credentials:

    docker exec -it csghub-omnibus cat /etc/csghub/init_root_password

5. Service Management

CSGHub provides two core command-line tools for routine management and maintenance.

5.1 csghub-ctl

The primary tool for managing all CSGHub services.

CommandDescription
reconfigureRefreshes configurations for all services after modifying /etc/csghub/csghub.yaml.
statusView the status of one or all services.
tailView real-time logs of specific or all services.
credsRetrieve credentials for common service components.
psqlInherits PostgreSQL PSQL commands for database operations.
mcInherits Minio mc commands for object storage operations.
kymlValidates and manages Kubernetes YAML manifests (Create, Update, Rebuild).

5.2 csghub-psql

Use this command to quickly log in to the built-in CSGHub PostgreSQL database without manually entering host addresses or usernames.

docker exec -it csghub-omnibus csghub-psql

6. Feedback

If you encounter any issues during installation or have feature suggestions, please submit your feedback here: