Tuesday, February 2, 2016

Grouping section data in gdeploy 1.1

The new release of gdeploy 1.1 has a cool new feature which allows users to group the ip-addresses/hostnames within the section headings.

Consider a scenario where there are four hosts whose disks have to be cleaned up for a fresh install. Two machines have vda disks and two more have vdb.

The configuration for such a setup looks like:


backend-reset.conf

[hosts]
10.70.46.159
10.70.46.172
10.70.46.185
10.70.47.129

[backend-reset:10.70.46.159]
pvs=vdb
unmount=yes

[backend-reset:10.70.46.185]
pvs=vdb
unmount=yes

[backend-reset:10.70.46.172]
pvs=vda
unmount=yes

[backend-reset:10.70.47.129]
pvs=vda
unmount=yes




The above configuration is quite long and gets tiresome to maintain as the number of nodes increase.

Thanks to Nandaja Varma, now the above configuration can be written as:


backend-reset.conf:


[hosts]
10.70.46.159
10.70.46.172
10.70.46.185
10.70.47.129

[backend-reset:10.70.46.{159,185}]
pvs=vdb
unmount=yes

[backend-reset:{10.70.46.172,10.70.47.129}]
pvs=vda
unmount=yes




Looks pretty neat and easy to maintain. Latest gdeploy release can be downloaded from here.

If you encounter any bugs please report them here.

No comments:

Post a Comment