Skip to content

Commit

Permalink
Add hammer plugin for foreman_puppet
Browse files Browse the repository at this point in the history
  • Loading branch information
amirfefer committed Aug 3, 2021
1 parent ae455be commit b55e9ad
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
10 changes: 10 additions & 0 deletions manifests/cli/puppet.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# = Hammer Puppet plugin
#
# This installs the Puppet plugin for Hammer CLI
#
# === Parameters:
#
class foreman::cli::puppet {
foreman::cli::plugin { 'foreman_puppet':
}
}
3 changes: 2 additions & 1 deletion spec/acceptance/foreman_cli_plugins_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,14 @@ class { 'foreman::cli':
include foreman::cli::tasks
include foreman::cli::templates
include foreman::cli::webhooks
include foreman::cli::puppet
PUPPET
end
end

it_behaves_like 'hammer'

['discovery', 'remote_execution', 'tasks', 'templates', 'webhooks'].each do |plugin|
['discovery', 'remote_execution', 'tasks', 'templates', 'webhooks', 'puppet'].each do |plugin|
package_name = case fact('os.family')
when 'RedHat'
"#{package_prefix}rubygem-hammer_cli_foreman_#{plugin}"
Expand Down
2 changes: 1 addition & 1 deletion spec/classes/cli_plugins_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

supported = on_supported_os

['ansible', 'azure', 'discovery', 'katello', 'kubevirt', 'openscap', 'remote_execution', 'tasks', 'templates', 'virt_who_configure', 'webhooks'].each do |plugin|
['ansible', 'azure', 'discovery', 'katello', 'kubevirt', 'openscap', 'remote_execution', 'tasks', 'templates', 'virt_who_configure', 'webhooks', 'puppet'].each do |plugin|
describe "foreman::cli::#{plugin}" do
supported.each do |os, os_facts|
context "on #{os}" do
Expand Down

0 comments on commit b55e9ad

Please sign in to comment.