Running ClickHouse in Docker

The documented start is the official image, clickhouse/clickhouse-server:26.9. Here every pull of it failed with a tls: bad record MAC network error, so the release's static binary (clickhouse-common-static from GitHub 29 , fetched with resumable curl 3,008 -C -) went into a small image FROM ubuntu:26.04 (demos/ch04/clickhouse/image/). That one 840 MB executable is server, client and clickhouse local:

The docker run line of ch_up.shShell
docker run -d --name l2-clickhouse --ulimit nofile=262144:262144 \
  -p 127.0.0.1:32123:8123 -p 127.0.0.1:32900:9000 \
  -v /home/dev/v7-l2/ch04:/var/lib/clickhouse/user_files/booknest:ro \
  l2/clickhouse-server:26.9.8.3

SELECT version() then returned 26.9.8.3, and the container idled at about 200 MiB. Port 8123 speaks HTTP, which BI tools and most drivers use; 9000 is the native protocol of clickhouse client. The nofile limit matters because each part holds a file per column.