We develop websites and we host the QA environment on the same server as the production environment. I want to serve a specific robots.txt for all QA sites but not for the production sites. We have a lot of sites so I do not want to manyallu update hundreds of vhost configuration blocks. The QA sites are easily identifyable from both the domain name and the directory they are in. QA and production sites are grouped in two different directories. All QA sites are hosted under *.qa.mycompany.com.
Example production: host: example.org docroot: /var/www/production/example.org
Example QA: host: example.qa.mycompany.com docroot: /var/www/qa/example.org
Is there any way to configure Apache to serve a robots.txt for all QA sites but not the production sites without having to update all QA vhost configs?