Sha256: fb11097ede94f2c0d90649d78eabf0a22be810ba89650598cc90f71dfd8c7a9e

Contents?: true

Size: 912 Bytes

Versions: 46

Compression:

Stored size: 912 Bytes

Contents

module Actions
  module Katello
    module Repository
      class CloneDockerContent < Actions::Base
        def plan(source_repo, target_repo, filters)
          filters = filters.docker unless filters.is_a? Array

          if filters.any?
            clause_gen = ::Katello::Util::DockerManifestClauseGenerator.new(source_repo, filters)
            clause_gen.generate
            copy_clauses = clause_gen.copy_clause
          end

          sequence do
            if filters.empty? || copy_clauses
              plan_action(Pulp::Repository::CopyDockerTag, source_pulp_id: source_repo.pulp_id,
                          target_pulp_id: target_repo.pulp_id, clauses: copy_clauses)
            end
            plan_action(Katello::Repository::MetadataGenerate, target_repo)
            plan_action(Katello::Repository::IndexContent, id: target_repo.id)
          end
        end
      end
    end
  end
end

Version data entries

46 entries across 46 versions & 1 rubygems

Version Path
katello-3.10.2 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.10.1.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.10.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.10.0 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.10.0.rc1.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.9.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.10.0.rc1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.9.0 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.8.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.9.0.rc2 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.9.0.rc1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.7.1.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.7.1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.8.0 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.8.0.rc3 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.8.0.rc2 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.7.0 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.8.0.rc1 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.7.0.rc2 app/lib/actions/katello/repository/clone_docker_content.rb
katello-3.7.0.rc1 app/lib/actions/katello/repository/clone_docker_content.rb