]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - 3rdparty/modules/apache/tests/vhost_ip_based.pp
add Openstack modules to 3rdparty
[dsa-puppet.git] / 3rdparty / modules / apache / tests / vhost_ip_based.pp
diff --git a/3rdparty/modules/apache/tests/vhost_ip_based.pp b/3rdparty/modules/apache/tests/vhost_ip_based.pp
new file mode 100644 (file)
index 0000000..dc0fa4f
--- /dev/null
@@ -0,0 +1,25 @@
+## IP-based vhosts on any listen port
+# IP-based vhosts respond to requests on specific IP addresses.
+
+# Base class. Turn off the default vhosts; we will be declaring
+# all vhosts below.
+class { 'apache':
+  default_vhost => false,
+}
+
+# Listen on port 80 and 81; required because the following vhosts
+# are not declared with a port parameter.
+apache::listen { '80': }
+apache::listen { '81': }
+
+# IP-based vhosts
+apache::vhost { 'first.example.com':
+  ip       => '10.0.0.10',
+  docroot  => '/var/www/first',
+  ip_based => true,
+}
+apache::vhost { 'second.example.com':
+  ip       => '10.0.0.11',
+  docroot  => '/var/www/second',
+  ip_based => true,
+}