From 612a665754f58ac76bb2ed590f077d34db6d34f6 Mon Sep 17 00:00:00 2001 From: Adam Jahn Date: Fri, 24 Aug 2012 15:57:09 -0400 Subject: interface and bind interface only options, bundled these together cause I can't think of a reason you'd set the interfaces without bind interfaces only --- manifests/server.pp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'manifests/server.pp') diff --git a/manifests/server.pp b/manifests/server.pp index b8e94b0..b3de661 100644 --- a/manifests/server.pp +++ b/manifests/server.pp @@ -1,4 +1,5 @@ -class samba::server($server_string = '', +class samba::server($interfaces = '', + $server_string = '', $workgroup = '') { include samba::server::install @@ -15,6 +16,16 @@ class samba::server($server_string = '', notify => Class['samba::server::service'] } + augeas { 'global-interfaces': + context => $context, + changes => $interfaces ? { + default => ["set \"${target}/interfaces\" '$interfaces'", "set \"${target}/bind interfaces only\" yes"], + '' => ["rm \"${target}/interfaces\"", "rm \"${target}/bind interfaces only\""], + }, + require => Augeas['global-section'], + notify => Class['samba::server::service'] + } + augeas { 'global-server_string': context => $context, changes => $server_string ? { -- cgit v1.2.3