Mentions légales du service

Skip to content
Snippets Groups Projects
Commit d4a61a0d authored by Lucas Nussbaum's avatar Lucas Nussbaum
Browse files

[dev] add support for removing rate when it's 0

parent ce30509e
No related branches found
No related tags found
No related merge requests found
...@@ -9,6 +9,13 @@ Dir['input/grid5000/sites/*/clusters/*/nodes/*.yaml'].each do |f| ...@@ -9,6 +9,13 @@ Dir['input/grid5000/sites/*/clusters/*/nodes/*.yaml'].each do |f|
# remove bios.configuration # remove bios.configuration
#d.values.first['bios'].delete('configuration') #d.values.first['bios'].delete('configuration')
# remove rate when it's 0
d.values.first['network_adapters'].each_pair do |name, na|
next if not na['rate']
next if na['rate'] != 0
na.delete('rate')
end
fd = File::new(f, 'w') fd = File::new(f, 'w')
fd.puts("# Generated by g5k-checks (g5k-checks -m api)") fd.puts("# Generated by g5k-checks (g5k-checks -m api)")
fd.puts d.to_yaml fd.puts d.to_yaml
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment