Skip to content

Commit

Permalink
fix(role::agent): radiorabe_zabbix_agent_extra_allow_key var instead …
Browse files Browse the repository at this point in the history
…of recursion (#15)
  • Loading branch information
hairmare authored Feb 24, 2024
1 parent 0950da5 commit 59d1507
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion roles/agent/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ Opinionated Zabbix agent installation
| Variable | Default |
| -------- | ------- |
| `radiorabe_zabbix_agent_server` | `monitoring.service.int.rabe.ch` |
| `radiorabe_zabbix_agent_serveractive | `monitoring.service.int.rabe.ch` |
| `radiorabe_zabbix_agent_serveractive` | `monitoring.service.int.rabe.ch` |
| `radiorabe_zabbix_agent_extra_allow_key` | `[]`, the role add some defaults that are sane for our case |

### Other Variables

Expand Down
2 changes: 2 additions & 0 deletions roles/agent/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
radiorabe_zabbix_agent_server: monitoring.service.int.rabe.ch
radiorabe_zabbix_agent_serveractive: monitoring.service.int.rabe.ch
radiorabe_zabbix_agent_extra_allow_key: []


_radiorabe_zabbix_agent_package_name: zabbix-agent2
_radiorabe_zabbix_agent_package_state: present
Expand Down
2 changes: 1 addition & 1 deletion roles/agent/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
zabbix_install_pip_packages: false
# config
zabbix_agent_dont_detect_ip: true
zabbix_agent2_allow_key: "{{ ( __radiorabe_zabbix_agent_allow_key + (zabbix_agent2_allow_key | default([]) ) | unique }}"
zabbix_agent2_allow_key: "{{ ( __radiorabe_zabbix_agent_allow_key + radiorabe_zabbix_agent_extra_allow_key ) | unique }}"
# environment specific
zabbix_agent2_server: "{{ radiorabe_zabbix_agent_server }}"
zabbix_agent2_serveractive: "{{ radiorabe_zabbix_agent_serveractive }}"
Expand Down

0 comments on commit 59d1507

Please sign in to comment.