Hi,
I am using ansible 2.1.0.0
Module using: ios_config
It seems that replace: block is not working.
Whenever changing one of my ntp_server ip addresses, only this ntp server is configured on my device.
All other NTS servers are deleted in config.
For me it looks like, “replace block” is ignored.
variable:
`
ntp_server_1: 78.46.40.125
ntp_server_2: 86.59.113.113
ntp_server_3: 93.185.134.30
`
playbook:
`
- name: enable NTP
ios_config:
host: “{{ inventory_hostname }}”
username: cisco
password: cisco
lines: - ntp server {{ntp_server_1}}
- ntp server {{ntp_server_2}}
- ntp server {{ntp_server_3}}
replace: block
before: [‘no ntp’]
match: line
`
Best regards
Markus