Closed KingJim1984 closed 10 months ago
Your firewall don't require name of policy ?
Your firewall don't require name of policy ?
Sorry, I edit my original post :) Yes my firewall need a name for the policy, I use a lot of different version of my ansible script and copy one without the name for the policy. But it is the same error with the name.
Hi @KingJim1984,
The mkey of this module is policyid, so name is optional here. The error is caused by the policyid == 0, you must provide the exact policyid instead of '0' to make sure the target object can be found.
The reason can be found here https://ansible-galaxy-fortios-docs.readthedocs.io/en/latest/gen/fortios_firewall_policy.html#notes and https://ansible-galaxy-fortios-docs.readthedocs.io/en/latest/faq.html#avoid-using-the-special-placeholder-0-as-the-mkey-in-some-modules
Thanks, Jie
Hi all,
I will close this issue as it's been a while and no further updates or responses have been received, indicating that the matter has likely been resolved or is no longer active.
If you have any further questions or concerns, please feel free to reopen the ticket or create a new one.
Hello all,
I'm taking the liberty of writing here instead of opening a new subject.
How can I add a new policy to an existing configuration if I can't use ID 0?
Knowing that the policy is modified manually as we go along (add, delete, modify) via the GUI. We therefore have no control over newly created policy IDs.
Regards.
Hello I try to add an simple firewall policy to my fortigate. But the deployment failed
Error message in Ansible:
diagnose debug application httpsd -1