services:
clickhouse:
image: clickhouse/clickhouse-server:23.8.4.69
ports:
# http interface
- "8123:8123"
# native interface for cliclkhiuse-client
- "9000:9000"
# metrics for prometheus
# - "19115:9115"
ulimits:
nofile:
soft: 262144
hard: 262144
volumes:
# - /etc/hosts:/etc/hosts
- /opt/docker-data/project/config.xml:/etc/clickhouse-server/config.xml
- /opt/docker-data/project/config.d/backup_disk.xml:/etc/clickhouse-server/config.d/backup_disk.xml
- /opt/docker-data/project/users.d/users.default.xml:/etc/clickhouse-server/users.d/users.default.xml
- /opt/docker-data/project/clickhousedb:/var/lib/clickhouse
- /opt/docker-data/project/clickhouselog:/var/log/clickhouse-server
Last active
December 21, 2023 09:18
-
-
Save kovalchukrs/3ddf0aa1c5453ce42f5e952f85405588 to your computer and use it in GitHub Desktop.
ClickHouse compose
Author
Author
backup_disk.xml
<clickhouse>
<storage_configuration>
<disks>
<backups>
<type>local</type>
<path>/var/lib/clickhouse/backups/</path>
</backups>
</disks>
</storage_configuration>
<backups>
<allowed_disk>backups</allowed_disk>
<allowed_path>/var/lib/clickhouse/backups/</allowed_path>
# <structure_only>true</structure_only>
# <allow_non_empty_tables>true</allow_non_empty_tables>
</backups>
</clickhouse>
Author
users.default.xml
<clickhouse>
<!-- Users and ACL. -->
<users>
<!-- If user name was not specified, 'default' user is used. -->
<default>
<!-- User can create other users and grant rights to them. -->
<access_management>1</access_management>
</default>
</users>
</clickhouse>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
config.xml