Altinity Stable Builds Docker Install Guide

How to install the Altinity Stable Builds for ClickHouse with Docker.

Installation Instructions: Docker

These included instructions detail how to install a single Altinity Stable build of ClickHouse container through Docker. For details on setting up a cluster of Docker containers, see ClickHouse on Kubernetes.

Docker Images are available for Altinity Stable builds and Community builds. The instructions below focus on using the Altinity Stable builds for ClickHouse.

The Docker repositories are located at:

To install a ClickHouse Altinity Stable build through Docker:

  1. Create the directory for the docker-compose.yml file and the database storage and ClickHouse server storage.

    mkdir clickhouse
    cd clickhouse
    mkdir clickhouse_database
    
  2. Create the file docker-compose.yml and populate it with the following, updating the clickhouse-server to the current altinity/clickhouse-server version:

    version: '3'
    
    services:
      clickhouse_server:
          image: altinity/clickhouse-server:21.8.10.1.altinitystable
          ports:
          - "8123:8123"
          volumes:
          - ./clickhouse_database:/var/lib/clickhouse
          networks:
              - clickhouse_network
    
    networks:
      clickhouse_network:
          driver: bridge
          ipam:
              config:
                  - subnet: 10.222.1.0/24
    
  3. Launch the ClickHouse Server with docker-compose or docker compose depending on your version of Docker:

    docker compose up -d
    
  4. Verify the installation by logging into the database from the Docker image directly, and make any other necessary updates with:

    docker compose exec clickhouse_server clickhouse-client
    root@67c732d8dc6a:/# clickhouse-client
    ClickHouse client version 21.3.15.2.altinity+stable (altinity build).
    Connecting to localhost:9000 as user default.
    Connected to ClickHouse server version 21.1.10 revision 54443.
    
    67c732d8dc6a :)
    
Last modified 2021.11.17: Updated Kubernetes, Altinity Stable