Skip to content

Commit

Permalink
Refs #34684 - enable pulp-cli for Katello
Browse files Browse the repository at this point in the history
  • Loading branch information
evgeni authored and ekohl committed Apr 5, 2022
1 parent 512bdc8 commit ec6f3e7
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
10 changes: 10 additions & 0 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,16 @@
before => Class['foreman_proxy::plugin::pulp'],
}

if $shared_with_foreman_vhost {
include certs::pulp_client
class { 'pulpcore::cli':
pulpcore_url => "https://${servername}",
dry_run => true,
cert => $certs::pulp_client::client_cert,
key => $certs::pulp_client::client_key,
}
}

if $enable_docker {
include pulpcore::plugin::container
unless $shared_with_foreman_vhost {
Expand Down
12 changes: 12 additions & 0 deletions spec/acceptance/content_with_foreman_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,16 @@ class { 'foreman_proxy_content':
it { is_expected.to be_file }
it { is_expected.to contain(%{DocumentRoot "/usr/share/foreman/public"}) }
end

describe command("pulp status") do
its(:exit_status) { is_expected.to eq 0 }
its(:stdout) { is_expected.to match(/versions/) }
its(:stderr) { is_expected.not_to match(/Error/) }
end

describe command("pulp user list") do
its(:exit_status) { is_expected.to eq 0 }
its(:stdout) { is_expected.to match(/admin/) }
its(:stderr) { is_expected.not_to match(/Error/) }
end
end

0 comments on commit ec6f3e7

Please sign in to comment.