diff options
author | Adam Leff <adam@leff.co> | 2017-09-15 17:35:03 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-15 17:35:03 -0400 |
commit | 9482fc44f30370253efdfc6ed9480434f2e2c9d0 (patch) | |
tree | be8dd7112d8a50067c4a2c6abdce40bef69f4cfd | |
parent | 2d5f77d920ef8036b5d5610458374cb38d72761d (diff) | |
parent | fae4135fa802fb3cc51006eac35ec8825d03e5b5 (diff) | |
download | ohai-9482fc44f30370253efdfc6ed9480434f2e2c9d0.tar.gz |
Merge pull request #1058 from chef/ipv6_colon_regex
Fix the route support for IPV6 routes ending in ::
-rw-r--r-- | lib/ohai/plugins/linux/network.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/ohai/plugins/linux/network.rb b/lib/ohai/plugins/linux/network.rb index 32a89133..296941fb 100644 --- a/lib/ohai/plugins/linux/network.rb +++ b/lib/ohai/plugins/linux/network.rb @@ -104,7 +104,8 @@ Ohai.plugin(:Network) do route_entry = Mash.new(:destination => route_dest, :family => family[:name]) %w{via scope metric proto src}.each do |k| - route_entry[k] = $1 if route_ending =~ /\b#{k}\s+([^\s]+)\b/ + # http://rubular.com/r/pwTNp65VFf + route_entry[k] = $1 if route_ending =~ /\b#{k}\s+([^\s]+)/ end # a sanity check, especially for Linux-VServer, OpenVZ and LXC: |