From 4d79949ce968bfef4b699d67ad2b647afcbe3c8f Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Thu, 13 Jan 2011 18:12:29 +0000 Subject: add a reverse proxy class --- modules/apache/manifests/init.pp | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'modules/apache/manifests/init.pp') diff --git a/modules/apache/manifests/init.pp b/modules/apache/manifests/init.pp index c98e2234..03eee275 100644 --- a/modules/apache/manifests/init.pp +++ b/modules/apache/manifests/init.pp @@ -80,6 +80,12 @@ class apache { mode => 644, } } + + class mod_proxy inherits base { + package { "apache-mod_proxy": + ensure => installed + } + } define vhost_redirect_ssl() { file { "redirect_ssl_$name.conf": @@ -177,6 +183,19 @@ class apache { } } + define vhost_reverse_proxy($url) { + include apache::mod_proxy + file { "$name.conf": + path => "/etc/httpd/conf/vhosts.d/$name.conf", + ensure => "present", + owner => root, + group => root, + mode => 644, + notify => Service['apache'], + content => template("apache/vhost_reverse_proxy.conf") + } + } + define webapp_other($webapp_file) { include apache::base $webappname = $name -- cgit v1.2.1