mirror of
https://gitea.0xace.cc/ansible-galaxy/victoriametrics.git
synced 2024-11-25 08:06:38 +00:00
33 lines
978 B
YAML
33 lines
978 B
YAML
- name: Install vmstorage {{ victoriametrics_vmstorage_version }}
|
|
dnf:
|
|
name: "vmstorage-{{ victoriametrics_vmstorage_version }}"
|
|
state: present
|
|
register: vmstorage_setup
|
|
notify: Restart vmstorage
|
|
|
|
- name: Create data directory {{ victoriametrics_vmstorage_data_dir }}
|
|
file:
|
|
path: "{{ victoriametrics_vmstorage_data_dir }}"
|
|
state: directory
|
|
owner: victoriametrics
|
|
group: victoriametrics
|
|
|
|
- name: Template vmstorage config
|
|
template:
|
|
src: etc/victoriametrics/vmcluster/vmstorage.conf.j2
|
|
dest: /etc/victoriametrics/vmcluster/vmstorage.conf
|
|
notify: Restart vmstorage
|
|
|
|
#- debug:
|
|
# msg: "{{ groups['vmstorage'] | map('extract', hostvars, ['ansible_host']) | join(':8400,') }}:8400"
|
|
|
|
#- debug:
|
|
# msg: "{{ groups['vmstorage'] | map('extract', hostvars, ['inventory_hostname']) | join(':8400,') }}:8400"
|
|
|
|
- name: Enable and start vmstorage service
|
|
systemd:
|
|
name: vmstorage
|
|
state: started
|
|
enabled: yes
|
|
daemon_reload: yes
|