Files
2024-07-12 12:58:40 +02:00

64 lines
1.9 KiB
YAML

---
# tasks file for windows_install-check-mk
# - name: download check_mk
# ansible.windows.win_get_url:
# url: https://monitoringeu.aperam.internal/monaperam/check_mk/agents/windows/check_mk_agent.msi
# dest: C:\Users\Public\Downloads\check_mk_agent.msi
# validate_certs: false
- name: copy installer to destination
ansible.windows.win_copy:
src: check_mk_agent.msi
dest: C:\Users\Public\Downloads\check_mk_agent.msi
- name: Install checkmk
win_package:
path: C:\Users\Public\Downloads\check_mk_agent.msi
# arguments:
# - /FORCERESTART
#creates_path: "{{ Directory }}"
creates_service: "Check MK Service"
state: present
register: package_output
ignore_errors: yes
- name: enable port 6556 on firewall
community.windows.win_firewall_rule:
name: checkmk
localport: 6556
action: allow
direction: in
protocol: tcp
state: present
enabled: yes
# - name: Add host
# tribe29.checkmk.host:
# server_url: "https://monitoringeu.aperam.internal/"
# site: "monaperam"
# automation_user: "ansible"
# automation_secret: "TJXTVH@GFYPRNCJCWUMY"
# host_name: "{{ ansible_fqdn }}"
# validate_certs: false
# state: present
# - name: "Add newly discovered services on host."
# tribe29.checkmk.discovery:
# server_url: "https://monitoringeu.aperam.internal/"
# site: "monaperam"
# automation_user: "ansible"
# automation_secret: "TJXTVH@GFYPRNCJCWUMY"
# host_name: "{{ ansible_fqdn }}"
# state: "new"
# validate_certs: false
# - name: "Activate changes on all sites."
# tribe29.checkmk.activation:
# server_url: "https://monitoringeu.aperam.internal/"
# site: "monaperam"
# automation_user: "ansible"
# automation_secret: "TJXTVH@GFYPRNCJCWUMY"
# force_foreign_changes: 'true'
# validate_certs: false
# run_once: 'true'