cloudamatic/mu

View on GitHub

Showing 2,704 of 2,705 total issues

Avoid more than 4 levels of block nesting.
Open

puts "#{nodename} - #{output}" if output.match(/[^\s]/)
Severity: Minor
Found in bin/mu-node-manage by rubocop

Useless assignment to variable - ebs_key.
Open

ebs_key = MU::Cloud::Azure.storage(credentials: credset).insert_object(
Severity: Minor
Found in bin/mu-azure-setup by rubocop

Avoid more than 4 levels of block nesting.
Open

newtree['default']['value'] = true if newtree['default']
Severity: Minor
Found in bin/mu-configure by rubocop

Use each_key instead of keys.each.
Open

commands.keys.each { |cmd|
Severity: Minor
Found in bin/mu-run-tests by rubocop

Prefer using YAML.safe_load over YAML.load.
Open

default_cfg.merge!(YAML.load(File.read("/opt/mu/etc/mu.yaml")))
Severity: Minor
Found in bin/mu-load-config.rb by rubocop

Do not suppress exceptions.
Open

rescue MU::Cloud::MuCloudResourceNotImplemented
Severity: Minor
Found in bin/mu-gen-docs by rubocop

Useless assignment to variable - e.
Open

rescue OpenURI::HTTPError, Timeout::Error, SocketError => e
Severity: Minor
Found in bin/mu-configure by rubocop

Useless assignment to variable - newmap. Use _ or _newmap as a variable name to indicate that it won't be used.
Open

newtree, newmap = menu(
Severity: Minor
Found in bin/mu-configure by rubocop

Useless assignment to variable - data.
Open

data = nil
Severity: Minor
Found in bin/mu-configure by rubocop

Avoid more than 4 levels of block nesting.
Open

cfg[key][name][subkey] = subdata['value'] if subdata['value']
Severity: Minor
Found in bin/mu-configure by rubocop

Avoid more than 4 levels of block nesting.
Open

next if nameentry.nil? or nameentry.match(/^#/)
Severity: Minor
Found in bin/mu-configure by rubocop

Use =~ in places where the MatchData returned by #match will not be used.
Open

if n.match(/^#{Regexp.quote(pool_name)}-[a-z0-9]{3}$/i)
Severity: Minor
Found in bin/mu-node-manage by rubocop

Use =~ in places where the MatchData returned by #match will not be used.
Open

if e.message.match(/User data is limited to (\d+)/)
Severity: Minor
Found in bin/mu-node-manage by rubocop

File.exists? is deprecated in favor of File.exist?.
Open

if File.exists?("/opt/opscode/bin/chef-server-ctl")
Severity: Minor
Found in bin/mu-gcp-setup by rubocop

Use meaningful heredoc delimiters.
Open

EOS
Severity: Minor
Found in bin/mu-deploy by rubocop

Useless assignment to variable - bucket. Did you mean bucketobj?
Open

bucket = MU::Cloud::Azure.storage(credentials: credset).insert_bucket(
Severity: Minor
Found in bin/mu-azure-setup by rubocop

Do not suppress exceptions.
Open

rescue OpenURI::HTTPError, SocketError
Severity: Minor
Found in bin/mu-configure by rubocop

Unused block argument - k. If it's necessary, use _ or _k as an argument name to indicate that it won't be used.
Open

map[count.to_s].each_pair { |k, v| v.delete("value") } # use defaults
Severity: Minor
Found in bin/mu-configure by rubocop

Unused block argument - key. If it's necessary, use _ or _key as an argument name to indicate that it won't be used.
Open

$CONFIGURABLES.each_pair { |key, data|
Severity: Minor
Found in bin/mu-configure by rubocop

Avoid rescuing the Exception class. Perhaps you meant to rescue StandardError?
Open

rescue Exception => e
MU.log e.inspect, MU::ERR, details: e.backtrace
exit 1
Severity: Minor
Found in bin/mu-node-manage by rubocop
Severity
Category
Status
Source
Language