Cookbook version
0.6.1
Chef-client version
12.x
Platform Details
RHEL
Scenario:
I'm upgrading a fleet of machines from 2.2 to 2.4 and in order to maintain compatibility with existing tools I'd like to keep the service name as "httpd", so all configuration would go in /etc/httpd/, and the init.d script would be /etc/init.d/httpd instead of /etc/init.d/httpd-<whatever>.
Judging by the following helper method that's used by httpd_service and httpd_config I don't think that's currently possible:
def apache_name
"httpd-#{instance}"
end
Ideally I'd like something like this:
# installs default 2.4 in /etc/httpd
httpd_service do
action "create"
end
# adds vhost config in /etc/httpd/conf.d
httpd_config "example" do
instance ""
source ...
template ...
end
# drop off the wsgi.load in /etc/init.d/conf.modules.d
httpd_module "wsgi" do
instance ""
action "create"
end