Closed kapouik closed 2 years ago
hi @kapouik will you follow up on this with a commit that fixes the code?
Sorry but I'm really bad with ruby. I have try to correct the code but for the moment, I don't have find how to patch correctly.
For the moment, I have this minor change that begin to correct one part of the code : https://github.com/kapouik/voxpupuli-puppet-network/blob/centos/lib/puppet/provider/network_route/redhat.rb#L61
# use the CIDR version of the target as :name
network, netmask = route[0].split('/')
prefix = IPAddr.new(netmask).to_i.to_s(2).count('1')
cidr_target = "#{network}/#{prefix}"
new_route[:name] = cidr_target
new_route[:network] = network
new_route[:netmask] = prefix
but it not correct parsing route-ethx files and it continu to write bad format.
All RHel/Centos version support format IP/prefixlen but RHel/Centos 7 don't support IP/netmask.
More detail on the issue 209.
As it, I have change the references files that are used to make test on redhat. After this change : travis-ci will fail all test.