This site is a static archive of the Aegir community site. Documentation has moved to http://docs.aegirproject.org. Other community resources can be found on the Contacting the community page.
Skip navigation

Revision of Conditional Logic for Injecting Apache Conf Rules from Mon, 08/06/2012 - 17:20

Help

Conditional Logic for Injecting Apache Conf Rules

Referenced Page: 
Injecting into site vhosts

I am trying to inject additional apache conf files so specific hosts, and I am using this code in a file called wwwlegacy.drush.inc in /var/aegir/.drush:

<? function wwwlegacy_provision_apache_vhost_config($uri, $data) { if ($uri == "cms.test.domain.com") { return array("Include conf.d/www-legacy-redirect.conf","Include conf.d/www-legacy-proxy.conf"); } } ?>

but this does not inject the two lines into the vhost entry of cms.test.domain.com after I verify the site. When I remove the if statement, it works, but I don't want it going to all the sites.

Looks like I am missing something very basic ... ?

Thanks!

Need help?

The revisions let you track differences between multiple versions of a post.

Discussion

The discussion area lets your team communicate by posting updates and discussing issues. It is a great place for sharing progress, discussing challenges, and exploring ideas.