ibikestl/puppet-netif — pull request #1 by tangledhelix (2013-04-25 19:40:06+00:00)
Title: IPv6 and alias changes/updates and one bugfix

One minor bugfix, which eliminates this error:

```
Dynamic lookup of $onparent at templates/alias.erb:21 is deprecated.
Support will be removed in Puppet 2.8. Use a fully-qualified variable
name (e.g., $classname::variable) or parameterized classes.
```

I added two new features. First is support for IPv6 addresses and routes. You can pass something like this to `netif::interface`.

``` puppet
ifaddr6 => 'abc:123:def:456::9ab/64',
routes6 => [
# default route
{ address => '::/0', gateway => 'abc:123:def:456::1' },
# static route
{ address => 'abc:123:def:489::/64', gateway => 'abc:123:def:456::1' },
],
```

Second is support for passing a list of aliases in as an array instead of specifying them as separate `netif::interface` instances. So instead of defining `eth0:1`, `eth0:2`, `eth0:3` and so on you can just pass this to `netif::interface` instead.

``` puppet
ifaddr => '1.2.3.1',
ifaddr6 => 'abc:123:def:456::9a3/64',
aliases => ['1.2.3.10', '1.2.3.11', '1.2.3.12'],
aliases6 => [
'abc:123:def:456::b04/64',
'abc:123:def:456::def/64',
'abc:123:def:456::c3d/64',
],
```

Disclaimer 1: this has only been tested on RHEL 6.4, and not exhaustively. I would guess it will work fine on any RHEL or Centos 6.x, but I will make no claim about RHEL/CentOS 5.x, which I'm not very familiar with.

Disclaimer 2: I'm scratching my own itch here, and I only needed support for `eth` devices. There's probably some missing coverage, e.g. `ib` and `br` interfaces. I don't have a good way to test those so I just ignored them.