script to edit all vhost at once. (cp a file into all of them)
I have 20 plones on a plone farm(varnish, apache2, zope & zeo), and some virtual hosts on the same server.
Now I would like to put a robots.txt on all of them, have anybody done a script which I can reuse or modify to accomplish my needs?
I guess that the script should do the next steps:
-check vhosts enabled (guess from apache2ctl -S and some awk)
-look for each root path (don't know get it from each vhost file, they are on different lines)
-check the file (robots.txt) does not exist (if -e)
-cp the file(robots.txt) to the root of each vhost. (cp)