Sha256: 95ddb45c3ea09dc6289b1b3593eae64a07085a8f85d02727ed0f7a3298f54db2

Contents?: true

Size: 657 Bytes

Versions: 49

Compression:

Stored size: 657 Bytes

Contents

module Actions
  module Pulp
    module Repos
      class Update < Pulp::Abstract
        def plan(product)
          sync_plan = product.sync_plan

          product.repos(product.library).each do |repo|
            if sync_plan.nil?
              plan_action(::Actions::Pulp::Repository::RemoveSchedule, :repo_id => repo.id)
            else
              plan_action(
                ::Actions::Pulp::Repository::UpdateSchedule,
                :repo_id => repo.id,
                :schedule => sync_plan.schedule_format,
                :enabled => sync_plan.enabled
              )
            end
          end
        end
      end
    end
  end
end

Version data entries

49 entries across 49 versions & 1 rubygems

Version Path
katello-3.8.1 app/lib/actions/pulp/repos/update.rb
katello-3.7.1.1 app/lib/actions/pulp/repos/update.rb
katello-3.7.1 app/lib/actions/pulp/repos/update.rb
katello-3.8.0 app/lib/actions/pulp/repos/update.rb
katello-3.8.0.rc3 app/lib/actions/pulp/repos/update.rb
katello-3.8.0.rc2 app/lib/actions/pulp/repos/update.rb
katello-3.7.0 app/lib/actions/pulp/repos/update.rb
katello-3.8.0.rc1 app/lib/actions/pulp/repos/update.rb
katello-3.7.0.rc2 app/lib/actions/pulp/repos/update.rb
katello-3.7.0.rc1 app/lib/actions/pulp/repos/update.rb
katello-3.5.2 app/lib/actions/pulp/repos/update.rb
katello-3.6.0 app/lib/actions/pulp/repos/update.rb
katello-3.6.0.1.rc2 app/lib/actions/pulp/repos/update.rb
katello-3.6.0.rc2 app/lib/actions/pulp/repos/update.rb
katello-3.6.0.rc1 app/lib/actions/pulp/repos/update.rb
katello-3.5.1.1 app/lib/actions/pulp/repos/update.rb
katello-3.5.1 app/lib/actions/pulp/repos/update.rb
katello-3.5.0.1 app/lib/actions/pulp/repos/update.rb
katello-3.5.0 app/lib/actions/pulp/repos/update.rb
katello-3.5.0.rc2 app/lib/actions/pulp/repos/update.rb