I have 2 servers, a master and a slave. The slave is used if the master is not accessible for any reasons.
Each server contains web application with apache/tomcat. I would like to replicate automatically some files and directories from the master to the slave each time a file or directory has changed.
For that I can use RSYNC (or UNISON, although replication is always from master to slave).
No problem to replicate the website application with RSYNC for example.
But I would like to replicate the configs files from apache too. If I change a value from the master's config file (httpd.conf), I would like to synchronize the change on the slave. But the problem is that some values are specific to each server, like IP address or other.
What is the best way to use replication with care of local specifications ?