ansible-collections / community.zabbix

Zabbix Ansible modules
http://galaxy.ansible.com/community/zabbix
Other
315 stars 265 forks source link

Agent: 2.5.0 fail to read existing PSK when role is not run with become: True #1247

Closed sblaisot closed 1 month ago

sblaisot commented 1 month ago
SUMMARY

When running agent role with psk and without become: True fail with

TASK [community.zabbix.zabbix_agent : AutoPSK | read existing TLS PSK file] ****
fatal: [target]: FAILED! => {"censored": "the output has been hidden due to the fact that 'no_log: true' was specified for this result", "changed": false}
ISSUE TYPE
COMPONENT NAME

Agent

CONFIGURATION
OS / ENVIRONMENT / Zabbix Version
STEPS TO REPRODUCE
roles:
  - role: community.zabbix.zabbix_agent
    [...]
      zabbix_agent_tlsconnect: psk
      zabbix_agent_tlsaccept: psk
      zabbix_agent_tlspskfile: "/etc/zabbix/agent.psk"
      zabbix_agent_tlspskidentity: "whatever"
      zabbix_agent_tlspsk_secret: "sUp3r_S3cr3T"
EXPECTED RESULTS

role install and configure zabbix agent

ACTUAL RESULTS

Role fails

TASK [community.zabbix.zabbix_agent : AutoPSK | read existing TLS PSK file] ****
fatal: [target]: FAILED! => {"censored": "the output has been hidden due to the fact that 'no_log: true' was specified for this result", "changed": false}

Fixed in #1246