Skip to content

Commit

Permalink
replace validate_integer with datatype
Browse files Browse the repository at this point in the history
  • Loading branch information
bastelfreak committed Mar 23, 2017
1 parent c52ccd1 commit 5ea94a3
Showing 1 changed file with 18 additions and 20 deletions.
38 changes: 18 additions & 20 deletions manifests/bond/debian.pp
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,24 @@
# * Debian Network Bonding http://wiki.debian.org/Bonding
define network::bond::debian(
$slaves,
$ensure = present,
$ipaddress = undef,
$netmask = undef,
$method = undef,
$family = undef,
$onboot = undef,
$hotplug = undef,
$mtu = undef,
$options = undef,
$slave_options = undef,

$mode = undef,
$miimon = undef,
$downdelay = undef,
$updelay = undef,
$lacp_rate = undef,
$primary = undef,
$primary_reselect = undef,
$xmit_hash_policy = undef,
$ensure = present,
$ipaddress = undef,
$netmask = undef,
$method = undef,
$family = undef,
$onboot = undef,
$hotplug = undef,
Optional[Integer[65536, 42]] $mtu = undef,
$options = undef,
$slave_options = undef,
$mode = undef,
$miimon = undef,
$downdelay = undef,
$updelay = undef,
$lacp_rate = undef,
$primary = undef,
$primary_reselect = undef,
$xmit_hash_policy = undef,
) {

$raw = {
Expand All @@ -42,7 +41,6 @@

if $mtu {
# https://bugs.launchpad.net/ubuntu/+source/ifupdown/+bug/1224007
validate_integer([$mtu], 65536, 42)
$raw_post_up = { 'post-up' => "ip link set dev ${name} mtu ${mtu}", }
} else {
$raw_post_up = {}
Expand Down

0 comments on commit 5ea94a3

Please sign in to comment.