Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #37191 - upload profile via REX #10900

Merged
merged 1 commit into from
Mar 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 16 additions & 0 deletions app/views/foreman/job_templates/upload_profile.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<%#
kind: job_template
name: Upload profile - Katello Script Default
job_category: Katello
model: JobTemplate
provider_type: script
description_format: Upload package profile for a host
feature: katello_upload_profile
%>
#!/bin/sh
<% if @host.operatingsystem.family == 'Redhat' -%>
dnf uploadprofile --force-upload
<% else -%>
package-profile-upload --force-upload
sbernhard marked this conversation as resolved.
Show resolved Hide resolved
<% end -%>
subscription-manager repos
1 change: 1 addition & 0 deletions lib/katello/plugin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,7 @@ def katello_template_setting_values(name)
RemoteExecutionFeature.register(:katello_service_restart, N_("Katello: Service Restart"), :description => N_("Restart Services via Katello interface"), :provided_inputs => ['helpers'])
RemoteExecutionFeature.register(:katello_host_tracer_resolve, N_("Katello: Resolve Traces"), :description => N_("Resolve traces via Katello interface"), :provided_inputs => ['ids'])
RemoteExecutionFeature.register(:katello_change_content_source, N_("Katello: Configure host for new content source"), :description => N_("Replace content source on the target machine"), :provided_inputs => [])
RemoteExecutionFeature.register(:katello_upload_profile, N_("Katello: Upload Profile"), :description => N_("Upload package / repos profile"), :provided_inputs => [])
RemoteExecutionFeature.register(:katello_module_stream_action, N_("Katello: Module Stream Actions"),
:description => N_("Perform a module stream action via Katello interface"),
:provided_inputs => ['action', 'module_spec', 'options'])
Expand Down