Project

General

Profile

« Previous | Next » 

Revision 8ce716a4

Added by Ewoud Kohl van Wijngaarden over 2 years ago

Fixes #34154 - Refresh on Pulp plugin installation

smart_proxy_pulp dynamically retrieves the Pulp content types and
Katello uses this. This means the features need to be refreshed after a
content type is added. The API also changes so that cache needs to be
regenerated.

This does refreshes on the foreman_smartproxy which could be considered
a private API from theforeman/foreman_proxy and collectors would
silently be skipped if anything changes. That's why this must be covered
by spec tests.

View differences:

manifests/init.pp
rhsm_path => $rhsm_path,
}
# smart_proxy_pulp dynamically retrieves the Pulp content types and Katello
# uses this. This means the features need to be refreshed after a content
# type is added. The API also changes so apipie cache needs to be regenerated.
# lint:ignore:spaceship_operator_without_tag
if $foreman_proxy::register_in_foreman {
Pulpcore::Plugin <| |> ~> Foreman_smartproxy[$foreman_proxy::registered_name]
Foreman_smartproxy[$foreman_proxy::registered_name] -> Foreman::Rake <| title == 'apipie:cache:index' |>
}
Pulpcore::Plugin <| |> ~> Foreman::Rake <| title == 'apipie:cache:index' |>
# lint:endignore
if $puppet {
# We can't pull the certs out to the top level, because of how it gets the default
# parameter values from the main certs class. Kafo can't handle that case, so
spec/classes/foreman_proxy_content_spec.rb
.with_rhsm_url("https://#{facts[:fqdn]}:443/rhsm")
end
context 'with foreman' do
let(:pre_condition) { 'include foreman' }
it { is_expected.to compile.with_all_deps }
it do
is_expected.to contain_foreman_smartproxy('foo.example.com')
.that_subscribes_to('Pulpcore::Plugin[rpm]')
.that_comes_before('Foreman::Rake[apipie:cache:index]')
end
it { is_expected.to contain_foreman__rake('apipie:cache:index').that_subscribes_to('Pulpcore::Plugin[rpm]') }
end
context 'with custom service worker timeouts' do
let(:params) do
{

Also available in: Unified diff