From 2c2e3608a251bdb8210767484e05c896f6803d6c Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 6 Sep 2012 11:29:17 +0200 Subject: beginning of openvpn server config --- puppet/manifests/site.pp | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 3a136015..39173f95 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,3 +1,15 @@ -node "default" { - notify {'Hello World':} +node 'cougar.leap.se' { + openvpn::server { + 'cougar.leap.se': + country => 'TR', + province => 'Ankara', + city => 'Ankara', + organization => 'leap.se', + email => 'sysdev@leap.se'; +} + +} + +node 'default' { + notify {'Please specify a host in site.pp!':} } -- cgit v1.2.3 From caeac390b217849e8e57ac3afeb4061099e3fec5 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 6 Sep 2012 12:10:21 +0200 Subject: use node default again, more openvpn config --- puppet/manifests/site.pp | 75 ++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 70 insertions(+), 5 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 39173f95..890d2623 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,4 +1,6 @@ -node 'cougar.leap.se' { +node 'default' { + notify {'Please specify a host in site.pp!':} + openvpn::server { 'cougar.leap.se': country => 'TR', @@ -6,10 +8,73 @@ node 'cougar.leap.se' { city => 'Ankara', organization => 'leap.se', email => 'sysdev@leap.se'; -} + } -} +# configure server + + + openvpn::option { + "dev server1": + key => "dev", + value => "tun0", + server => "server1"; + "script-security server1": + key => "script-security", + value => "3", + server => "server1"; + "daemon server1": + key => "daemon", + server => "server1"; + "keepalive server1": + key => "keepalive", + value => "10 60", + server => "server1"; + "ping-timer-rem server1": + key => "ping-timer-rem", + server => "server1"; + "persist-tun server1": + key => "persist-tun", + server => "server1"; + "persist-key server1": + key => "persist-key", + server => "server1"; + "proto server1": + key => "proto", + value => "tcp-server", + server => "server1"; + "cipher server1": + key => "cipher", + value => "BF-CBC", + server => "server1"; + "local server1": + key => "local", + value => $ipaddress, + server => "server1"; + "tls-server server1": + key => "tls-server", + server => "server1"; + "server server1": + key => "server", + value => "10.10.10.0 255.255.255.0", + server => "server1"; + "lport server1": + key => "lport", + value => "1194", + server => "server1"; + "management server1": + key => "management", + value => "/var/run/openvpn-server1.sock unix", + server => "server1"; + "comp-lzo server1": + key => "comp-lzo", + server => "server1"; + "topology server1": + key => "topology", + value => "subnet", + server => "server1"; + "client-to-client server1": + key => "client-to-client", + server => "server1"; + } -node 'default' { - notify {'Please specify a host in site.pp!':} } -- cgit v1.2.3 From 72987f7f86bd322e8ea68ff2633c76a29c6c2f95 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 6 Sep 2012 12:14:06 +0200 Subject: more openvpn config testing --- puppet/manifests/site.pp | 74 +++++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 36 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 890d2623..de551aed 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,8 +1,10 @@ node 'default' { notify {'Please specify a host in site.pp!':} + $openvpn_server='cougar.leap.se' + openvpn::server { - 'cougar.leap.se': + "$openvpn_server": country => 'TR', province => 'Ankara', city => 'Ankara', @@ -14,67 +16,67 @@ node 'default' { openvpn::option { - "dev server1": + "dev $openvpn_server": key => "dev", value => "tun0", - server => "server1"; - "script-security server1": + server => "$openvpn_server"; + "script-security $openvpn_server": key => "script-security", value => "3", - server => "server1"; - "daemon server1": + server => "$openvpn_server"; + "daemon $openvpn_server": key => "daemon", - server => "server1"; - "keepalive server1": + server => "$openvpn_server"; + "keepalive $openvpn_server": key => "keepalive", value => "10 60", - server => "server1"; - "ping-timer-rem server1": + server => "$openvpn_server"; + "ping-timer-rem $openvpn_server": key => "ping-timer-rem", - server => "server1"; - "persist-tun server1": + server => "$openvpn_server"; + "persist-tun $openvpn_server": key => "persist-tun", - server => "server1"; - "persist-key server1": + server => "$openvpn_server"; + "persist-key $openvpn_server": key => "persist-key", - server => "server1"; - "proto server1": + server => "$openvpn_server"; + "proto $openvpn_server": key => "proto", value => "tcp-server", - server => "server1"; - "cipher server1": + server => "$openvpn_server"; + "cipher $openvpn_server": key => "cipher", value => "BF-CBC", - server => "server1"; - "local server1": + server => "$openvpn_server"; + "local $openvpn_server": key => "local", value => $ipaddress, - server => "server1"; - "tls-server server1": + server => "$openvpn_server"; + "tls-server $openvpn_server": key => "tls-server", - server => "server1"; - "server server1": + server => "$openvpn_server"; + "server $openvpn_server": key => "server", value => "10.10.10.0 255.255.255.0", - server => "server1"; - "lport server1": + server => "$openvpn_server"; + "lport $openvpn_server": key => "lport", value => "1194", - server => "server1"; - "management server1": + server => "$openvpn_server"; + "management $openvpn_server": key => "management", - value => "/var/run/openvpn-server1.sock unix", - server => "server1"; - "comp-lzo server1": + value => "/var/run/openvpn-$openvpn_server.sock unix", + server => "$openvpn_server"; + "comp-lzo $openvpn_server": key => "comp-lzo", - server => "server1"; - "topology server1": + server => "$openvpn_server"; + "topology $openvpn_server": key => "topology", value => "subnet", - server => "server1"; - "client-to-client server1": + server => "$openvpn_server"; + "client-to-client $openvpn_server": key => "client-to-client", - server => "server1"; + server => "$openvpn_server"; } } -- cgit v1.2.3 From bdfcfbb8702748ab013190b0116735fe56f7531e Mon Sep 17 00:00:00 2001 From: varac Date: Fri, 7 Sep 2012 13:06:00 +0200 Subject: use hiere for openvpn CA --- puppet/manifests/site.pp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index de551aed..0d1f426d 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,15 +1,15 @@ node 'default' { notify {'Please specify a host in site.pp!':} - $openvpn_server='cougar.leap.se' + $openvpn_server=$::fqdn openvpn::server { "$openvpn_server": - country => 'TR', - province => 'Ankara', - city => 'Ankara', - organization => 'leap.se', - email => 'sysdev@leap.se'; + country => hiera("country"), + province => hiera("province"), + city => hiera("city"), + organization => hiera("organization"), + email => hiera("email"); } # configure server -- cgit v1.2.3 From 429944efaac25766a5999966d8f52f74a0e0292b Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 20 Sep 2012 11:49:52 +0200 Subject: using class site_openvpn --- puppet/manifests/site.pp | 86 ++++-------------------------------------------- 1 file changed, 7 insertions(+), 79 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 0d1f426d..1bfc730e 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,82 +1,10 @@ node 'default' { - notify {'Please specify a host in site.pp!':} - - $openvpn_server=$::fqdn - - openvpn::server { - "$openvpn_server": - country => hiera("country"), - province => hiera("province"), - city => hiera("city"), - organization => hiera("organization"), - email => hiera("email"); - } - -# configure server - - - openvpn::option { - "dev $openvpn_server": - key => "dev", - value => "tun0", - server => "$openvpn_server"; - "script-security $openvpn_server": - key => "script-security", - value => "3", - server => "$openvpn_server"; - "daemon $openvpn_server": - key => "daemon", - server => "$openvpn_server"; - "keepalive $openvpn_server": - key => "keepalive", - value => "10 60", - server => "$openvpn_server"; - "ping-timer-rem $openvpn_server": - key => "ping-timer-rem", - server => "$openvpn_server"; - "persist-tun $openvpn_server": - key => "persist-tun", - server => "$openvpn_server"; - "persist-key $openvpn_server": - key => "persist-key", - server => "$openvpn_server"; - "proto $openvpn_server": - key => "proto", - value => "tcp-server", - server => "$openvpn_server"; - "cipher $openvpn_server": - key => "cipher", - value => "BF-CBC", - server => "$openvpn_server"; - "local $openvpn_server": - key => "local", - value => $ipaddress, - server => "$openvpn_server"; - "tls-server $openvpn_server": - key => "tls-server", - server => "$openvpn_server"; - "server $openvpn_server": - key => "server", - value => "10.10.10.0 255.255.255.0", - server => "$openvpn_server"; - "lport $openvpn_server": - key => "lport", - value => "1194", - server => "$openvpn_server"; - "management $openvpn_server": - key => "management", - value => "/var/run/openvpn-$openvpn_server.sock unix", - server => "$openvpn_server"; - "comp-lzo $openvpn_server": - key => "comp-lzo", - server => "$openvpn_server"; - "topology $openvpn_server": - key => "topology", - value => "subnet", - server => "$openvpn_server"; - "client-to-client $openvpn_server": - key => "client-to-client", - server => "$openvpn_server"; - } + $service='eip' + $password=hiera('testpw') + $openvpn_ports=hiera_array('openvpn_ports') + $tor=hiera('tor') + notify {"Password: $password":} + notify {"Openvpn Config for $fqdn: openvpn_ports=$openvpn_ports, tor=$tor":} + #include site_openvpn } -- cgit v1.2.3 From 764ae6f21a8a54af78b29fc14876af36e2dd4651 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 20 Sep 2012 13:39:23 +0200 Subject: parse new config layout --- puppet/manifests/site.pp | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 1bfc730e..bb29e393 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,10 +1,22 @@ +define print() { + notice("The value is: '${name}'") +} + + node 'default' { - $service='eip' - $password=hiera('testpw') - $openvpn_ports=hiera_array('openvpn_ports') - $tor=hiera('tor') - notify {"Password: $password":} - notify {"Openvpn Config for $fqdn: openvpn_ports=$openvpn_ports, tor=$tor":} - #include site_openvpn + #$password=hiera('testpw') + #notify {"Password: $password":} + + $services=hiera_array('services') + notice("Services for $fqdn: $services") + + if 'eip' in $services { + $openvpn_ports=hiera_array('openvpn_ports') + $tor=hiera('tor') + notice("Openvpn Config for $fqdn: openvpn_ports=$openvpn_ports, tor=$tor") + print{$openvpn_ports:} + #include site_openvpn + } + } -- cgit v1.2.3 From 75e57c74d5aa0595e02435ca4de15b9df1cc6002 Mon Sep 17 00:00:00 2001 From: varac Date: Fri, 21 Sep 2012 12:45:36 +0200 Subject: parsing of hiera config hash works --- puppet/manifests/site.pp | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index bb29e393..abb81511 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,7 +1,15 @@ define print() { - notice("The value is: '${name}'") + notice("The value is: '${name}'") +} + +define create_openvpn_config($port, $protocol) { + $openvpn_configname=$name + notice("Creating OpenVPN $openvpn_configname: + Port: $port, Protocol: $protocol") + # ... + #include site_openvpn + } - node 'default' { #$password=hiera('testpw') @@ -11,12 +19,9 @@ node 'default' { notice("Services for $fqdn: $services") if 'eip' in $services { - $openvpn_ports=hiera_array('openvpn_ports') + $openvpn=hiera('openvpn') $tor=hiera('tor') - notice("Openvpn Config for $fqdn: openvpn_ports=$openvpn_ports, tor=$tor") - print{$openvpn_ports:} - #include site_openvpn + notice("Tor enabled: $tor") + create_resources('create_openvpn_config', $openvpn) } - - } -- cgit v1.2.3 From 1c5eb8a64426c93d8118acac52870a6a95f73010 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 21 Sep 2012 15:03:08 +0200 Subject: oved things around --- puppet/manifests/site.pp | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index abb81511..98e683af 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -2,26 +2,18 @@ define print() { notice("The value is: '${name}'") } -define create_openvpn_config($port, $protocol) { - $openvpn_configname=$name - notice("Creating OpenVPN $openvpn_configname: - Port: $port, Protocol: $protocol") - # ... - #include site_openvpn - -} - node 'default' { - #$password=hiera('testpw') - #notify {"Password: $password":} + $concat_basedir = '/var/lib/puppet/modules/concat' + include concat::setup $services=hiera_array('services') notice("Services for $fqdn: $services") if 'eip' in $services { - $openvpn=hiera('openvpn') $tor=hiera('tor') notice("Tor enabled: $tor") - create_resources('create_openvpn_config', $openvpn) + + $openvpn_config=hiera('openvpn') + create_resources('site_openvpn::server_config', $openvpn_config) } } -- cgit v1.2.3 From 276de1e249b25e5e00c49229132215681aee6467 Mon Sep 17 00:00:00 2001 From: varac Date: Fri, 21 Sep 2012 20:26:20 +0200 Subject: basic configuration for openvpn server files --- puppet/manifests/site.pp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 98e683af..f7b7303f 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,19 +1,18 @@ -define print() { - notice("The value is: '${name}'") -} - node 'default' { - $concat_basedir = '/var/lib/puppet/modules/concat' + # $concat_basedir = '/var/lib/puppet/modules/concat' # do we need this ? include concat::setup $services=hiera_array('services') notice("Services for $fqdn: $services") if 'eip' in $services { + include site_openvpn + $tor=hiera('tor') notice("Tor enabled: $tor") - $openvpn_config=hiera('openvpn') - create_resources('site_openvpn::server_config', $openvpn_config) + $openvpn_configs=hiera('openvpn_server_configs') + create_resources('site_openvpn::server_config', $openvpn_configs) + } } -- cgit v1.2.3 From 8320de2fd5bd8fcb429dfc1b68527a1c39a8341f Mon Sep 17 00:00:00 2001 From: varac Date: Sun, 23 Sep 2012 19:02:28 +0200 Subject: reorderd config, include site_sshd --- puppet/manifests/site.pp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index f7b7303f..a897de11 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -5,6 +5,14 @@ node 'default' { $services=hiera_array('services') notice("Services for $fqdn: $services") + # configure ssh and inculde ssh-keys + #include sshd + $ssh_keys=hiera_hash('ssh_keys') + include site_sshd + notice($ssh_keys) + create_resources('site_sshd::ssh_key', $ssh_keys) + + if 'eip' in $services { include site_openvpn -- cgit v1.2.3 From b6f07a78502ecbe850c0b798dfdd0fdb60a78425 Mon Sep 17 00:00:00 2001 From: varac Date: Mon, 24 Sep 2012 18:32:40 +0200 Subject: include some basic mclasses --- puppet/manifests/site.pp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index a897de11..f70c0673 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,6 +1,10 @@ node 'default' { + + # include some basic classes # $concat_basedir = '/var/lib/puppet/modules/concat' # do we need this ? include concat::setup + include apt,git,lsb + $services=hiera_array('services') notice("Services for $fqdn: $services") @@ -21,6 +25,6 @@ node 'default' { $openvpn_configs=hiera('openvpn_server_configs') create_resources('site_openvpn::server_config', $openvpn_configs) - } + } -- cgit v1.2.3 From e73a5e34742a63d82ee4b1a84a779403d9f71bd7 Mon Sep 17 00:00:00 2001 From: varac Date: Mon, 24 Sep 2012 18:41:37 +0200 Subject: include common --- puppet/manifests/site.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index f70c0673..5f58a733 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -3,8 +3,8 @@ node 'default' { # include some basic classes # $concat_basedir = '/var/lib/puppet/modules/concat' # do we need this ? include concat::setup - include apt,git,lsb - + include apt, lsb, git + import "common" $services=hiera_array('services') notice("Services for $fqdn: $services") -- cgit v1.2.3 From 8c078cbe1c607e0cb2df917196c00eade55b3a01 Mon Sep 17 00:00:00 2001 From: varac Date: Mon, 24 Sep 2012 22:20:57 +0200 Subject: test class couchdb --- puppet/manifests/site.pp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 5f58a733..3b28be2f 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -27,4 +27,9 @@ node 'default' { create_resources('site_openvpn::server_config', $openvpn_configs) } + if 'couchdb' in $services { + class { 'couchdb': + #bind => '0.0.0.0' + } + } } -- cgit v1.2.3 From e5244f7015de9ffd88c20e9b8136996bfbfe0f0d Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 4 Oct 2012 16:08:07 +0200 Subject: added site_config::eip --- puppet/manifests/site.pp | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 5f58a733..3ae9ebea 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -4,7 +4,7 @@ node 'default' { # $concat_basedir = '/var/lib/puppet/modules/concat' # do we need this ? include concat::setup include apt, lsb, git - import "common" + import 'common' $services=hiera_array('services') notice("Services for $fqdn: $services") @@ -18,13 +18,7 @@ node 'default' { if 'eip' in $services { - include site_openvpn - - $tor=hiera('tor') - notice("Tor enabled: $tor") - - $openvpn_configs=hiera('openvpn_server_configs') - create_resources('site_openvpn::server_config', $openvpn_configs) + include site_config::eip } } -- cgit v1.2.3 From b7277a8c666248a2a134f1d5b84c994df9904b7c Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 4 Oct 2012 22:34:20 +0200 Subject: moved most includes to site_config --- puppet/manifests/site.pp | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 3ae9ebea..89c97888 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,22 +1,16 @@ node 'default' { + # prerequisites + import 'common' + include concat::setup # include some basic classes - # $concat_basedir = '/var/lib/puppet/modules/concat' # do we need this ? - include concat::setup - include apt, lsb, git - import 'common' + #include site_config + # parse services for host $services=hiera_array('services') notice("Services for $fqdn: $services") - # configure ssh and inculde ssh-keys - #include sshd - $ssh_keys=hiera_hash('ssh_keys') - include site_sshd - notice($ssh_keys) - create_resources('site_sshd::ssh_key', $ssh_keys) - - + # configure eip if 'eip' in $services { include site_config::eip } -- cgit v1.2.3 From 9fc9b19057fcf322e8d3fcaead0032859f873f53 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 11 Oct 2012 19:49:48 +0200 Subject: renamed hiera keys to work with leap_cli --- puppet/manifests/site.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 89c97888..d451bdf5 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -11,7 +11,7 @@ node 'default' { notice("Services for $fqdn: $services") # configure eip - if 'eip' in $services { + if 'openvpn' in $services { include site_config::eip } -- cgit v1.2.3 From 01732be30c06919f85e4887a500f7e9b11e56e4f Mon Sep 17 00:00:00 2001 From: varac Date: Sat, 13 Oct 2012 11:08:22 +0200 Subject: use site_couchdb --- puppet/manifests/site.pp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index ef5c3a8a..e0b573ce 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -15,9 +15,7 @@ node 'default' { include site_config::eip } - if 'couchdb' in $services { - class { 'couchdb': - #bind => '0.0.0.0' - } + if 'couchdb' in $services { + include site_couchdb } } -- cgit v1.2.3 From 3c244c02f4c6ddd6f361297ab63e41905fac96e5 Mon Sep 17 00:00:00 2001 From: varac Date: Sat, 13 Oct 2012 11:14:55 +0200 Subject: include site_config again --- puppet/manifests/site.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index e0b573ce..6abf9b48 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -4,7 +4,7 @@ node 'default' { include concat::setup # include some basic classes - #include site_config + include site_config # parse services for host $services=hiera_array('services') -- cgit v1.2.3 From b1c8c57b1fb028ea4ce8c8954bfdad9b9e7f2766 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Tue, 20 Nov 2012 16:20:37 -0500 Subject: setup webapp in site.pp --- puppet/manifests/site.pp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 6abf9b48..70c97030 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -18,4 +18,8 @@ node 'default' { if 'couchdb' in $services { include site_couchdb } + + if 'webapp' in $services { + include site_webapp + } } -- cgit v1.2.3 From c2d57624c15dfaff038f9991f04ade46b5ad1d40 Mon Sep 17 00:00:00 2001 From: varac Date: Wed, 21 Nov 2012 17:45:44 +0100 Subject: move site_config::eip to site_openvpn (Feature #943) --- puppet/manifests/site.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 6abf9b48..0ae86f8e 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -12,7 +12,7 @@ node 'default' { # configure eip if 'openvpn' in $services { - include site_config::eip + include site_openvpn } if 'couchdb' in $services { -- cgit v1.2.3 From 6f6d29c43da75b1bd8d2068f8c7cf3ffd0064580 Mon Sep 17 00:00:00 2001 From: varac Date: Tue, 4 Dec 2012 14:18:24 +0100 Subject: use site_ca --- puppet/manifests/site.pp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 9da2174c..304e989d 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -22,4 +22,8 @@ node 'default' { if 'webapp' in $services { include site_webapp } + + if 'ca' in $services { + include site_ca + } } -- cgit v1.2.3 From 51f37d8132a44e25350db66b7156892980d3e4fa Mon Sep 17 00:00:00 2001 From: varac Date: Fri, 7 Dec 2012 14:48:55 +0100 Subject: ca -> ca_daemon in site.pp and services/ca.json --- puppet/manifests/site.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 304e989d..c8502bc7 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -24,6 +24,6 @@ node 'default' { } if 'ca' in $services { - include site_ca + include site_ca_daemon } } -- cgit v1.2.3 From ff1c732fbe76abe8fcb39e82233ad76e6acf3ab8 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Thu, 17 Jan 2013 14:31:24 -0500 Subject: set a default exec path for all nodes --- puppet/manifests/site.pp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index c8502bc7..a1917d6e 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,3 +1,6 @@ +# set a default exec path +Exec { path => '/usr/bin:/usr/sbin/:/bin:/sbin:/usr/local/bin:/usr/local/sbin' } + node 'default' { # prerequisites import 'common' -- cgit v1.2.3 From 65d28a5e43ce3005b0560763809a09f64bfcfea7 Mon Sep 17 00:00:00 2001 From: varac Date: Sat, 26 Jan 2013 18:41:56 +0100 Subject: apply site_nagios::server --- puppet/manifests/site.pp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index a1917d6e..94835f61 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -29,4 +29,8 @@ node 'default' { if 'ca' in $services { include site_ca_daemon } + + if 'monitoring' in $services { + include site_nagios::server + } } -- cgit v1.2.3 From 078bc9674c247cc2c3ad715eec57903138e481e1 Mon Sep 17 00:00:00 2001 From: varac Date: Sun, 27 Jan 2013 11:15:36 +0100 Subject: added 'development' hiera hash to exclude certain class for better testing --- puppet/manifests/site.pp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 94835f61..1a76e3bd 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -6,8 +6,13 @@ node 'default' { import 'common' include concat::setup - # include some basic classes - include site_config + $development = hiera('development') + if $development['site_config'] == true { + # include some basic classes + include site_config + } else { + notice ('NOT applying site_config') + } # parse services for host $services=hiera_array('services') @@ -30,7 +35,7 @@ node 'default' { include site_ca_daemon } - if 'monitoring' in $services { + if 'monitor' in $services { include site_nagios::server } } -- cgit v1.2.3 From d0bec7ba086aadefba3655509db6c5b25b116bfb Mon Sep 17 00:00:00 2001 From: varac Date: Tue, 29 Jan 2013 16:39:23 +0100 Subject: run stage declaration moved to site.pp --- puppet/manifests/site.pp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 1a76e3bd..33566f0c 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -1,6 +1,10 @@ # set a default exec path Exec { path => '/usr/bin:/usr/sbin/:/bin:/sbin:/usr/local/bin:/usr/local/sbin' } +stage { 'initial': + before => Stage['main'], +} + node 'default' { # prerequisites import 'common' @@ -11,7 +15,7 @@ node 'default' { # include some basic classes include site_config } else { - notice ('NOT applying site_config') + notice ('NOT applying site_config') } # parse services for host -- cgit v1.2.3 From ab9a292f41139c5c5e36de87e03236e29dd27e23 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 31 Jan 2013 11:09:20 +0100 Subject: puppet tags: site_config::default and site_config::slow --- puppet/manifests/site.pp | 66 +++++++++++++++++++++--------------------------- 1 file changed, 29 insertions(+), 37 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 33566f0c..146b373e 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -5,41 +5,33 @@ stage { 'initial': before => Stage['main'], } -node 'default' { - # prerequisites - import 'common' - include concat::setup - - $development = hiera('development') - if $development['site_config'] == true { - # include some basic classes - include site_config - } else { - notice ('NOT applying site_config') - } - - # parse services for host - $services=hiera_array('services') - notice("Services for $fqdn: $services") - - # configure eip - if 'openvpn' in $services { - include site_openvpn - } - - if 'couchdb' in $services { - include site_couchdb - } - - if 'webapp' in $services { - include site_webapp - } - - if 'ca' in $services { - include site_ca_daemon - } - - if 'monitor' in $services { - include site_nagios::server - } +# prerequisites +import 'common' +include concat::setup +include site_config::default +include site_config::slow + +# parse services for host +$services=hiera_array('services') +notice("Services for ${fqdn}: ${services}") + +# configure eip +if 'openvpn' in $services { + include site_openvpn +} + +if 'couchdb' in $services { + include site_couchdb +} + +if 'webapp' in $services { + include site_webapp +} + +if 'ca' in $services { + include site_ca_daemon +} + +if 'monitor' in $services { + include site_nagios::server } -- cgit v1.2.3 From ced1717ae310c5b24fffd041c8af38b016d90ed4 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 31 Jan 2013 11:40:41 +0100 Subject: include site_nagios so every subclass inherits tag 'service' --- puppet/manifests/site.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 146b373e..d422bef7 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -33,5 +33,5 @@ if 'ca' in $services { } if 'monitor' in $services { - include site_nagios::server + include site_nagios } -- cgit v1.2.3 From 0ab18bc91fa84df2c457ca1ea43ebebc65e5bb2b Mon Sep 17 00:00:00 2001 From: varac Date: Fri, 1 Feb 2013 21:46:06 +0100 Subject: moved concat::setup to site_config::default Because in site.pp it didn't get the tag "leap_base" and would not be declared with leap cli's default puppet tags. Fixes: parent directory /var/lib/puppet/concat does not exist (Feature#1625) --- puppet/manifests/site.pp | 2 -- 1 file changed, 2 deletions(-) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index d422bef7..53b452d1 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -5,9 +5,7 @@ stage { 'initial': before => Stage['main'], } -# prerequisites import 'common' -include concat::setup include site_config::default include site_config::slow -- cgit v1.2.3 From 4642e8a0780f1eb6ba14fdf1f2966101dab993f7 Mon Sep 17 00:00:00 2001 From: varac Date: Wed, 6 Feb 2013 23:58:17 +0100 Subject: add basic tor service --- puppet/manifests/site.pp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'puppet/manifests') diff --git a/puppet/manifests/site.pp b/puppet/manifests/site.pp index 53b452d1..1ec806d9 100644 --- a/puppet/manifests/site.pp +++ b/puppet/manifests/site.pp @@ -33,3 +33,7 @@ if 'ca' in $services { if 'monitor' in $services { include site_nagios } + +if 'tor' in $services { + include site_tor +} -- cgit v1.2.3