I am writing Ansible playbook to automate my DRBD setup and I will include multiple roles on a single system. As a result, each role will have to append drbdlinks configuration with its own link directive.
The usual way to ease such modular configuration is to include files available in a .d configuration directory.
Here is a work-around I have implemented directly at the end of drbdlinks.conf because I found out it was passed through execfile
import glob
for conf in glob.iglob('/etc/drbdlinks.d/*.conf'):
execfile(conf)
I am writing Ansible playbook to automate my DRBD setup and I will include multiple roles on a single system. As a result, each role will have to append drbdlinks configuration with its own
link
directive.The usual way to ease such modular configuration is to include files available in a
.d
configuration directory.Here is a work-around I have implemented directly at the end of
drbdlinks.conf
because I found out it was passed throughexecfile