Day 85: A Task That Always Changes and Two Halves
Post · https://dev.to/ndcodes/day-85-one-direction-and-two-halves-5cic
Day 85 of DevOps, Day 35 of Azure. Both tasks today reported a state that is a word rather than a...
First seen by Oriel on .
AI summary
This Day 85 DevOps/Azure exercise shows why Ansible’s state: touch is non-idempotent and Azure VNet peering requires both directional resources, while VirtualNetwork NSG rules silently expand.
- The Ansible task creates /tmp/file.txt on App Server 01, but state: touch updates timestamps by default and reports changed=1 on every run.
- Setting modification_time: preserve and access_time: preserve makes the file-creation task idempotent while retaining the required empty file.
- Azure peering requires one child resource on each VNet; one side remains Initiated and routes no traffic, while both sides reach Connected.
- Azure injects VNetPeering routes automatically after connection, but a user-defined route can override them and --allow-vnet-access false can still block forwarding.
- The VirtualNetwork service tag permits traffic from peered networks, gateways, and user-defined-route prefixes, silently broadening NSG access without changing the NSG itself.
#ansible #azure vnet peering #network security groups #idempotence
Generated by gpt-5.6-sol. Check the original for details.
Metric trends
Last 30 days · Up to 120 recorded samples per source and metric, with reposts kept separate · First and latest retained
Reactions
Total public reactions reported by the source; distinct from points and likes.
- DEV Community: 16, latest observation ; 0 over observed period since
Comments
Comment count reported by the source.
- DEV Community: 2, latest observation ; +1 over observed period since
Aliases
| Source | External ID | URL |
|---|---|---|
| DEV Community | 5041988 | https://dev.to/ndcodes/day-85-one-direction-and-two-halves-5cic Read discussion |