diff --git a/CHANGELOG.md b/CHANGELOG.md
index d970a4a..3ed86b5 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,13 @@ This project adheres to [Semantic Versioning](http://semver.org/) and [Keep a ch
## [Unreleased](https://github.com/idealista/clickhouse_role/tree/develop)
+## [3.5.0(https://github.com/idealista/clickhouse_role/tree/3.5.0 (2024-01-31)
+
+### :heavy_plus_sign: Added
+
+- [#70](https://github.com/idealista/clickhouse_role/issues/70) Include extra config and users files
+- Update default lts version to latest (23.8.9.54)
+
## [3.4.1(https://github.com/idealista/clickhouse_role/tree/3.4.1 (2024-01-26)
### :hammer_and_wrench: Fixed
diff --git a/defaults/main.yml b/defaults/main.yml
index b429553..c05cd05 100644
--- a/defaults/main.yml
+++ b/defaults/main.yml
@@ -2,7 +2,7 @@
## General
# Version
-clickhouse_version: 22.8.8.3
+clickhouse_version: 23.8.9.54
clickhouse_release_type: lts # Values should be: stable, lts or testing
clickhouse_install_db: True
clickhouse_install_bridge: False
@@ -83,6 +83,8 @@ clickhouse_user_files_directory: "{{ clickhouse_base_path }}/user_files"
clickhouse_access_control_directory: "{{ clickhouse_base_path }}/access/"
# clickhouse_custom_config_file_path: "{{ playbook_dir }}/config_files/config"
# clickhouse_custom_users_file_path: "{{ playbook_dir }}/config_files/users"
+# clickhouse_custom_extra_config_file_path: "{{ playbook_dir }}/config_files/config/config.d"
+# clickhouse_custom_extra_users_file_path: "{{ playbook_dir }}/config_files/users/users.d"
# Logs
clickhouse_logger:
diff --git a/molecule/default/config_files/config/config.d/log_disable.xml b/molecule/default/config_files/config/config.d/log_disable.xml
new file mode 100644
index 0000000..53ceca2
--- /dev/null
+++ b/molecule/default/config_files/config/config.d/log_disable.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/molecule/default/config_files/users/users.d/log_queries.xml b/molecule/default/config_files/users/users.d/log_queries.xml
new file mode 100644
index 0000000..ae6a6b9
--- /dev/null
+++ b/molecule/default/config_files/users/users.d/log_queries.xml
@@ -0,0 +1,8 @@
+
+
+
+ 0
+ 0
+
+
+
\ No newline at end of file
diff --git a/molecule/default/group_vars/clickhouse_group.yml b/molecule/default/group_vars/clickhouse_group.yml
index 880b535..f0a3a2c 100644
--- a/molecule/default/group_vars/clickhouse_group.yml
+++ b/molecule/default/group_vars/clickhouse_group.yml
@@ -13,8 +13,8 @@ clickhouse_role_manage_settings_profiles: True
clickhouse_role_manage_quotas: True
clickhouse_role_manage_grants: True
-# clickhouse_custom_config_file_path: "{{ playbook_dir }}/config_files/config"
-# clickhouse_custom_users_file_path: "{{ playbook_dir }}/config_files/users"
+clickhouse_custom_extra_config_file_path: "{{ playbook_dir }}/config_files/config/config.d"
+clickhouse_custom_extra_users_file_path: "{{ playbook_dir }}/config_files/users/users.d"
# Users
clickhouse_admin_user: admin
diff --git a/molecule/default/tests/test_app.yml b/molecule/default/tests/test_app.yml
index 283c89d..e0f6eb0 100644
--- a/molecule/default/tests/test_app.yml
+++ b/molecule/default/tests/test_app.yml
@@ -31,6 +31,16 @@ file:
group: {{ clickhouse_group }}
exists: true
filetype: file
+ "{{ clickhouse_config_directory_config_d }}/log_disable.xml":
+ owner: {{ clickhouse_user }}
+ group: {{ clickhouse_group }}
+ exists: true
+ filetype: file
+ "{{ clickhouse_config_directory_users_d }}/log_queries.xml":
+ owner: {{ clickhouse_user }}
+ group: {{ clickhouse_group }}
+ exists: true
+ filetype: file
service:
{{ clickhouse_service }}:
diff --git a/tasks/config/clickhouse.yml b/tasks/config/clickhouse.yml
index b88b28c..37eb628 100644
--- a/tasks/config/clickhouse.yml
+++ b/tasks/config/clickhouse.yml
@@ -20,6 +20,16 @@
notify: "{{ clickhouse_handler_on_config_change }}"
tags: clickhouse_configure
+- name: CLICKHOUSE | Add extra configuration files
+ copy:
+ src: "{{ clickhouse_custom_extra_config_file_path }}/"
+ dest: "{{ clickhouse_config_directory_config_d }}/"
+ owner: "{{ clickhouse_user }}"
+ group: "{{ clickhouse_group }}"
+ mode: 0644
+ when: clickhouse_custom_extra_config_file_path is defined
+ tags: clickhouse_configure
+
- name: CLICKHOUSE | Configure users (from vars)
template:
src: "{{ clickhouse_users_file_name }}.j2"
@@ -43,3 +53,13 @@
tags:
- clickhouse_configure
- clickhouse_users
+
+- name: CLICKHOUSE | Add extra user configuration files
+ copy:
+ src: "{{ clickhouse_custom_extra_users_file_path }}/"
+ dest: "{{ clickhouse_config_directory_users_d }}/"
+ owner: "{{ clickhouse_user }}"
+ group: "{{ clickhouse_group }}"
+ mode: 0644
+ when: clickhouse_custom_extra_users_file_path is defined
+ tags: clickhouse_configure