16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
# File 'app/lib/actions/candlepin/product/content_create.rb', line 16
def run
content_url = input[:content_url]
if input[:type] == ::Katello::Repository::DEB_TYPE
repository = ::Katello::Repository.find(input[:repository_id])
content_url += repository.deb_content_url_options
end
output[:response] = ::Katello::Resources::Candlepin::Content.
create(input[:owner],
name: input[:name],
contentUrl: content_url,
type: input[:type],
arches: input[:arches],
label: input[:label],
requiredTags: input[:os_versions],
metadataExpire: 1,
vendor: ::Katello::Provider::CUSTOM)
end
|