]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - modules/ganeti2/manifests/init.pp
dedicated ganeti ssh chain
[dsa-puppet.git] / modules / ganeti2 / manifests / init.pp
index 7a472e07329278dcdb87a8e2e40c7b0c86b73e83..7d44ee1da596a57c59b961f966069a38193e80dd 100644 (file)
@@ -8,9 +8,47 @@ class ganeti2 {
                ensure => installed
        }
 
-       @ferm::rule { 'dsa-ganeti-v4':
-               description => 'Allow ganeti from ganeti master',
-               rule        => 'proto tcp mod state state (NEW) dport (1811) @subchain \'ganeti\' { saddr ($HOST_GANETI_V4) ACCEPT; }',
+       package { 'ganeti-instance-debootstrap':
+               ensure => installed
+       }
+
+       package { 'ganeti-htools':
+               ensure => installed
+       }
+
+       @ferm::rule { 'dsa-ganeti-noded-v4':
+               description => 'allow ganeti-noded communication between',
+               rule        => 'proto tcp mod state state (NEW) dport (1811) @subchain \'ganeti-noded\' { saddr ($HOST_GANETI_V4) daddr ($HOST_GANETI_V4) ACCEPT; }',
+               notarule    => true,
+       }
+
+       @ferm::rule { 'dsa-ganeti-confd-v4':
+               description => 'allow ganeti-confd communication',
+               rule        => 'proto udp mod state state (NEW) dport (1814) @subchain \'ganeti-confd\' { saddr ($HOST_GANETI_V4) daddr ($HOST_GANETI_V4) ACCEPT; }',
+               notarule    => true,
+       }
+
+       @ferm::rule { 'dsa-ganeti-rapi-v4':
+               description => 'allow ganeti-rapi communication',
+               rule        => 'proto tcp mod state state (NEW) dport (5080) @subchain \'ganeti-rapi\' { saddr ($HOST_GANETI_V4) daddr ($HOST_GANETI_V4) ACCEPT; }',
+               notarule    => true,
+       }
+
+       @ferm::rule { 'dsa-drbd-v4':
+               description => 'allow drbd communication',
+               rule        => 'proto tcp mod state state (NEW) dport (11000:11999) @subchain \'drbd\' { saddr ($HOST_GANETI_BACKEND_V4) daddr ($HOST_GANETI_BACKEND_V4) ACCEPT; }',
+               notarule    => true,
+       }
+
+       @ferm::rule { 'dsa-ganeti-migrate':
+               description => 'allow kvm to migrate instances',
+               rule        => 'proto tcp dport 8102 @subchain \'ganeti-migrate\' { saddr ($HOST_GANETI_BACKEND_V4) daddr ($HOST_GANETI_BACKEND_V4) ACCEPT; }',
+               notarule    => true,
+       }
+
+       @ferm::rule { 'dsa-ganeti-ssh':
+               description => 'allow ganeti to ssh around',
+               rule        => 'proto tcp dport ssh @subchain \'ganeti-ssh\' { saddr ( $HOST_GANETI_V4 $HOST_GANETI_BACKEND_V4) ACCEPT; }',
                notarule    => true,
        }
 }