Skip to content

yandex/ch-tools

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

4df613e · Apr 17, 2024
Apr 15, 2024
Apr 17, 2024
Nov 3, 2023
Jun 21, 2023
Apr 17, 2024
Aug 21, 2023
Nov 13, 2023
Aug 14, 2023
Jul 10, 2023
Nov 27, 2023
May 31, 2023
Feb 28, 2024
Aug 30, 2023
Nov 27, 2023
Nov 27, 2023
Jan 31, 2024
Apr 17, 2024

Repository files navigation

license tests status chat

clickhouse-tools

clickhouse-tools is a set of tools for administration and diagnostics of ClickHouse DBMS.

Tools

clickhouse-tools consist of following components:

All of these tools must be run on the same host as ClickHouse server is running.

Local development (using poetry)

sudo make install-poetry
# or to install in user's home directory
make POETRY_HOME=~/opt/poetry install-poetry

# lint
make lint

# unit tests
make test-unit
make test-unit PYTEST_ARGS="-k test_name"

# integration tests (rebuild docker images using a .whl file)
make test-integration
make test-integration BEHAVE_ARGS="-i feature_name"

# integration tests (supply a custom ClickHouse version to test against)
CLICKHOUSE_VERSION="1.2.3.4" make test-integration
# If you want to have containers running on failure, supply a flag:
# BEHAVE_ARGS="-D no_stop_on_fail"

# For building deb packages
make prepare-build-deb
make build-deb-package  

Please note: base images for tests are pulled from chtools Dockerhub. If you want to build base images locally, run

docker buildx bake -f tests/bake.hcl

If you want to build base images for multiple versions of ClickHouse, run:

CLICKHOUSE_VERSIONS='1.2.3.4, 5.6.7.8, latest' docker buildx bake -f tests/bake.hcl