diff options
author | Leif Johansson <leifj@sunet.se> | 2015-05-26 13:16:49 +0200 |
---|---|---|
committer | Leif Johansson <leifj@sunet.se> | 2015-05-26 13:16:49 +0200 |
commit | d284dcced21429aa414f21b4f5e67bdebc651971 (patch) | |
tree | b7f1a85a8671e3ca268597ae68d93b446ab68bd0 /global/overlay/etc/puppet | |
parent | 726fced83ba306910e2e1ce91d40da5db04358d1 (diff) |
known roots, nw configct-ops-2015-05-26-v01
Diffstat (limited to 'global/overlay/etc/puppet')
5 files changed, 33 insertions, 20 deletions
diff --git a/global/overlay/etc/puppet/manifests/catlfish/frontend.pp b/global/overlay/etc/puppet/manifests/catlfish/frontend.pp index df1b932..e441083 100644 --- a/global/overlay/etc/puppet/manifests/catlfish/frontend.pp +++ b/global/overlay/etc/puppet/manifests/catlfish/frontend.pp @@ -1,10 +1,11 @@ define catlfish::frontend( + $logname = undef, $image = 'docker.sunet.se/ctct/catlfish-dev', $version = 'latest' ) { $base = '/var/local/db' - $db = ""${base}/${name}" + $db = ""${base}/${logname}" file {$base: ensure => directory } -> file {$db: ensure => directory } -> sunet::docker_run{"${name}_varnish": @@ -20,12 +21,12 @@ define catlfish::frontend( env => ["BACKEND_PORT=tcp://${name}_varnish.docker:80"], ports => ["443:443"] } -> - sunet::docker_run {'${name}_frontend': + sunet::docker_run {"${name}_catlfish": image => $image, imagetag => $version, ports => ["8080:8080","8082:8082"], volumes => ["/usr/local/etc/catlfish:/usr/local/etc/catlfish:ro","${db}:/var/local/db/catlfish"], - command => ["frontend"] + command => ["frontend ${name}"] } -> ufw::allow { "${name}-allow-http": ip => 'any', diff --git a/global/overlay/etc/puppet/manifests/catlfish/merge.pp b/global/overlay/etc/puppet/manifests/catlfish/merge.pp index df69e91..9334b09 100644 --- a/global/overlay/etc/puppet/manifests/catlfish/merge.pp +++ b/global/overlay/etc/puppet/manifests/catlfish/merge.pp @@ -1,17 +1,18 @@ define catlfish::merge( + $logname = undef, $image = 'docker.sunet.se/ctct/catlfish-dev', $version = 'latest' ) { $base = '/var/local/db' - $db = ""${base}/${name}" + $db = ""${base}/${logname}" file {$base: ensure => directory } -> file {$db: ensure => directory } -> - sunet::docker_run {'${name}_merge': + sunet::docker_run {"${name}_catlfish": image => $image, - env => ["MERGE_EXTRA_ARGS=--timing"], + env => ["MERGE_EXTRA_ARGS=--timing","MERGE_DB_DIR=/var/local/db/catlfish"], imagetag => $version, - volumes => ["/usr/local/etc/catlfish:/usr/local/etc/catlfish:ro","${db}:/var/local/db/catlfish"], - command => ["merge /var/local/db/catlfish"] + volumes => ["/usr/local/etc/catlfish/${name}:/usr/local/etc/catlfish:ro","${db}:/var/local/db/catlfish"], + command => ["merge ${name}"] } } diff --git a/global/overlay/etc/puppet/manifests/catlfish/signing.pp b/global/overlay/etc/puppet/manifests/catlfish/signing.pp index 40b3f9c..bef855b 100644 --- a/global/overlay/etc/puppet/manifests/catlfish/signing.pp +++ b/global/overlay/etc/puppet/manifests/catlfish/signing.pp @@ -1,14 +1,15 @@ define catlfish::signing( + $logname = undef, $image = 'docker.sunet.se/ctct/catlfish-dev-lunahsm', $version = 'latest' ) { - sunet::docker_run {'${name}_signing': + sunet::docker_run {"${name}_catlfish": image => $image, imagetag => $version, volumes => ["/usr/local/etc/catlfish:/usr/local/etc/catlfish:ro"], ports => ["8188:8188"], - command => ["signing"] + command => ["signing ${name}"] } ufw:allow { "${name}-allow-8188-acl0": ip => '130.242.125.0/24', diff --git a/global/overlay/etc/puppet/manifests/catlfish/storage.pp b/global/overlay/etc/puppet/manifests/catlfish/storage.pp index a325f3e..2e7191e 100644 --- a/global/overlay/etc/puppet/manifests/catlfish/storage.pp +++ b/global/overlay/etc/puppet/manifests/catlfish/storage.pp @@ -1,18 +1,19 @@ define catlfish::storage( + $logname = undef, $image = 'docker.sunet.se/ctct/catlfish-dev', $version = 'latest' ) { $base = '/var/local/db' - $db = "${base}/${name}" + $db = "${base}/${logname}" file {$base: ensure => directory } -> file {$db: ensure => directory } -> - sunet::docker_run {'${name}_storage': + sunet::docker_run {"${name}_catlfish": image => $image, imagetag => $version, volumes => ["/usr/local/etc/catlfish:/usr/local/etc/catlfish:ro","${db}:/var/local/db/catlfish"], ports => ["8081:8081"], - command => ["storage"] + command => ["storage ${name}"] } ufw:allow { "${name}-allow-8081-acl0": ip => '130.242.125.0/24', diff --git a/global/overlay/etc/puppet/manifests/cosmos-site.pp b/global/overlay/etc/puppet/manifests/cosmos-site.pp index 1499e64..54841f5 100644 --- a/global/overlay/etc/puppet/manifests/cosmos-site.pp +++ b/global/overlay/etc/puppet/manifests/cosmos-site.pp @@ -149,15 +149,24 @@ node 'm0.ct.nordu.net' { } } -class frontend { - catlfish::frontend { 'urd': } - catlfish::storage { 'urd': } +node 'NOTYET_frontend-1.urd.appendto.org' { + catlfish::frontend { 'frontend-1': logname => 'urd.appendto.org' } + catlfish::storage { 'storage-1': logname => 'urd.appendto.org' } } -class merge { - catlfish::merge {'urd': } +node 'NOTYET_frontend-2.urd.appendto.org' { + catlfish::frontend { 'frontend-2': logname => 'urd.appendto.org' } + catlfish::storage { 'storage-2': logname => 'urd.appendto.org' } } -class signing { - catlfish::signing {'urd': } +node 'NOTYET_merge-1.urd.appendto.org' { + catlfish::merge { 'merge-1': logname => 'urd.appendto.org' } +} + +node 'NOTYET_sign-1.urd.appendto.org' { + catlfish::signing {'signing-1': logname => 'urd.appendto.org' } +} + +node 'NOTYET_sign-2.urd.appendto.org' { + catlfish::signing {'signing-2': logname => 'urd.appendto.org' } } |