How to make variant DNS config on windows following hosts group

Hi everybody

I’m looking for a way to deploy different DNS host config following the hosts group of Windows Servers
The main goal is to load balance in fault of true proxy DNS.

For exemple:

[HOST GROUP1]

Winserver1
Winserver2
Winserver3

[HOST GROUP2]

Winserver4
Winserver5
Winserver6

[HOST GROUP3]

Winserver7
Winserver8
Winserver9

HOST GROUP 1 = > DNS: 192.168.10.10,192.168.10.11,192.168.10.12

HOST GROUP 2 = > DNS: 192.168.10.11,192.168.10.12,192.168.10.10

HOST GROUP 3 = > DNS: 192.168.10.12,192.168.10.10,192.168.10.11

Thank you for your help

Happy new year

Georges

`
Something like this?

group_vars/host_group1.yml

Hi mike,

Yes exactly like this.

Same question for 400 Linux servers.
I wan’t to have 4 groups with each group have différent DNS config.
Is there way to do this only using ansible yml and no scripting bash ?

Thanks