This role installs Prometheus' Windows exporter on Windows hosts.
N/A
Available variables are listed below, along with default values (see defaults/main.yml
):
windows_exporter_version: '0.18.1'
The version of Windows exporter to install. Available releases can be found on the tags listing in the Windows exporter repository. Drop the v
off the tag.
If you change the version, the windows_exporter
binary will be replaced with the updated version, and the service will be restarted.
windows_exporter_arch: 'amd64'
windows_exporter_download_url: https://github.com/prometheus-community/windows_exporter/releases/download/v{{ windows_exporter_version }}/windows_exporter-{{ windows_exporter_version }}-{{ windows_exporter_arch }}.msi
windows_exporter_bin_path: 'C:\Windows\temp\windows_exporter-{{ windows_exporter_version }}-{{ windows_exporter_arch }}.msi'
The path where the windows_exporter
binary will be downloaded and installed from.
windows_exporter_listen_address: '0.0.0.0'
windows_exporter_listen_port: 9182
windows_exporter_textfile_dir: null
Commonly used service options.
windows_exporter_options: ''
Any additional options to pass to windows_exporter
when it starts, e.g. --no-collector.wifi
if you want to ignore any WiFi data.
Need to use MSI Parameters as stated in https://github.com/prometheus-community/windows_exporter#installation
windows_exporter_state: started
windows_exporter_start_mode: delayed
Controls for the windows_exporter
service. windows_exporter_start_mode
controls the start_mode of the service. windows_exporter_state
controls the state of the service on the host.
None.
- hosts: all
roles:
- role: danielweeber.windows_exporter
MIT / BSD
This role was created in 2021 by Daniel Weeber. Heavily inspired and forked from Jeff Geerling, author of Ansible for DevOps.