Sha256: 902380548d3e63c9b3a4e3ea42dc265c6f1cebe15d61d5ff5623b06c83234bd7

Contents?: true

Size: 907 Bytes

Versions: 113

Compression:

Stored size: 907 Bytes

Contents

module Katello
  module Pulp
    module ImporterComparison
      def importer_matches?(generated_importer, capsule_importer)
        if capsule_importer.try(:[], 'importer_type_id') != generated_importer.id
          return false
        end

        generated_config = generated_importer.config
        capsule_config = capsule_importer['config']
        if generated_config['proxy_host'] == ""
          proxy_keys = %w(proxy_host proxy_username proxy_password)
          proxy_keys.each do |key|
            generated_config.delete(key)
            capsule_config.delete(key)
          end
        end

        if generated_config['proxy_password'] == "" && capsule_config['proxy_password'] == "*****"
          generated_config.delete('proxy_password')
          capsule_config.delete('proxy_password')
        end

        generated_config.compact == capsule_config.compact
      end
    end
  end
end

Version data entries

113 entries across 113 versions & 1 rubygems

Version Path
katello-4.2.0.1.rc3 app/services/katello/pulp/importer_comparison.rb
katello-3.18.5 app/services/katello/pulp/importer_comparison.rb
katello-4.2.0.1.rc2 app/services/katello/pulp/importer_comparison.rb
katello-4.2.0.rc2 app/services/katello/pulp/importer_comparison.rb
katello-4.1.3 app/services/katello/pulp/importer_comparison.rb
katello-4.2.0.rc1 app/services/katello/pulp/importer_comparison.rb
katello-4.0.2.1 app/services/katello/pulp/importer_comparison.rb
katello-4.1.2.1 app/services/katello/pulp/importer_comparison.rb
katello-4.0.2 app/services/katello/pulp/importer_comparison.rb
katello-4.1.2 app/services/katello/pulp/importer_comparison.rb
katello-3.18.4 app/services/katello/pulp/importer_comparison.rb
katello-4.1.1 app/services/katello/pulp/importer_comparison.rb
katello-4.1.0 app/services/katello/pulp/importer_comparison.rb
katello-4.0.1.2 app/services/katello/pulp/importer_comparison.rb
katello-3.18.3.1 app/services/katello/pulp/importer_comparison.rb
katello-4.1.0.rc2.2 app/services/katello/pulp/importer_comparison.rb
katello-4.1.0.rc2.1 app/services/katello/pulp/importer_comparison.rb
katello-4.0.1.1 app/services/katello/pulp/importer_comparison.rb
katello-3.18.3 app/services/katello/pulp/importer_comparison.rb
katello-4.1.0.rc2 app/services/katello/pulp/importer_comparison.rb