katello 3.11.0.rc1 → 3.11.0.rc2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of katello might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6a32463caf56384a932ac684b0b75d47c98ae21e6b3b3bbca2b66a4f0cf6d5c9
4
- data.tar.gz: 708211d7fd9d19eebf438ae7656aba6425bbeab7e93118adc44480af84e48b5c
3
+ metadata.gz: 33692b74c9a55f4c19bfe2791e7b6ea3c9e480441f8e6069916702f12d061287
4
+ data.tar.gz: 534f1a11e88cecf4a44218d51019cf2aaa567b310314c9dc415ab0b3e09ebd56
5
5
  SHA512:
6
- metadata.gz: 80f6db1719414ea26a9391e4a245961a580b050c62e0f8dfa355fe9d00398e629c2b04c87e810b374af8a0328497881301e110f9b090ef48888d2f6d368df948
7
- data.tar.gz: b9676a10313f563208e0982ecdf209886ea17d19755ffe52f42303ebed127ce42994c35bca39e3fd016e442b67edbe3f2a68340a3b58c57f7006783949a67f51
6
+ metadata.gz: 3bd83f58ccd7cc236b1de78e2c8004ad6a870791b9bb9cfc4b2051d5af29fe71d1df61a4cb177473a07c88fb057cd2703c247eaa909684332cd7b6bc3a848564
7
+ data.tar.gz: 844f4cac7b5f9263c0b7a4c3883d1a53cf8fb73626860cda4ca94b66875022b5a60c8e25557442770700b6bfe58d5f661448bbb3371aa7779be1cb6b339f710d
@@ -4,7 +4,7 @@ module Katello
4
4
  include Katello::Concerns::Api::V2::RepositoryContentController
5
5
 
6
6
  before_action :find_host, :only => [:index, :available_errata]
7
- before_action :find_optional_organization, :only => :available_errata
7
+ before_action :find_optional_organization, :only => [:index, :auto_complete_search, :available_errata]
8
8
  before_action :find_environment, :only => :available_errata
9
9
  before_action :find_filter, :only => :available_errata
10
10
 
@@ -1,3 +1,4 @@
1
+ # rubocop:disable HandleExceptions
1
2
  require 'fileutils'
2
3
  require 'English'
3
4
 
@@ -35,6 +36,11 @@ module Actions
35
36
  delete_tmp_files(tmp_files) if $ERROR_INFO && tmp_files
36
37
  end
37
38
 
39
+ def run
40
+ ForemanTasks.async_task(Repository::CapsuleSync, ::Katello::Repository.find(input[:repository][:id]))
41
+ rescue ::Katello::Errors::CapsuleCannotBeReached # skip any capsules that cannot be connected to
42
+ end
43
+
38
44
  def humanized_name
39
45
  _("Upload into")
40
46
  end
@@ -19,7 +19,7 @@ module Katello
19
19
  end
20
20
 
21
21
  def generate_distributors
22
- puppet_install_dist = Runcible::Models::PuppetInstallDistributor.new(puppet_install_distributor_path, :id => repo.pulp_id, :auto_publish => false)
22
+ puppet_install_dist = Runcible::Models::PuppetInstallDistributor.new(puppet_install_distributor_path, :subdir => 'modules', :id => repo.pulp_id, :auto_publish => false)
23
23
  puppet_dist = Runcible::Models::PuppetDistributor.new(nil, (root.unprotected || false), true,
24
24
  :id => "#{repo.pulp_id}_puppet", :auto_publish => true)
25
25
  [puppet_dist, puppet_install_dist]
@@ -27,7 +27,7 @@ module Katello
27
27
 
28
28
  def puppet_install_distributor_path
29
29
  puppet_env = ::Environment.construct_name(repo.organization, repo.environment, repo.content_view)
30
- ::File.join(smart_proxy.puppet_path, puppet_env, 'modules')
30
+ ::File.join(smart_proxy.puppet_path, puppet_env)
31
31
  end
32
32
 
33
33
  def partial_repo_path
@@ -29,12 +29,12 @@ module Katello
29
29
  self.id.to_s <=> other.id.to_s
30
30
  end
31
31
 
32
- def as_json(options = {})
33
- ret = super(options)
34
- ret[:name] = self.id.to_s
35
- ret[:creatable] = @allow_creation_by_user
36
- ret.delete("allow_creation_by_user")
37
- ret
32
+ def as_json(_options = {})
33
+ {
34
+ :name => self.id.to_s,
35
+ :id => self.id,
36
+ :creatable => @allow_creation_by_user
37
+ }
38
38
  end
39
39
  end
40
40
  end
@@ -16,7 +16,7 @@ module BastionKatello
16
16
  :name => 'bastion_katello',
17
17
  :javascript => proc do
18
18
  [
19
- javascript_include_tag(*webpack_asset_paths('katello_common', :extension => 'js'), "data-turbolinks-track" => true),
19
+ javascript_include_tag(*webpack_asset_paths('katello:common', :extension => 'js'), "data-turbolinks-track" => true),
20
20
  javascript_include_tag('bastion_katello/bastion_katello')
21
21
  ]
22
22
  end,
@@ -5,10 +5,17 @@ namespace :katello do
5
5
  task :update_puppet_repos => %w(environment) do
6
6
  User.current = User.anonymous_admin
7
7
  Katello::Repository.puppet_type.each do |repo|
8
- puts "Refreshing repository #{repo.label} (#{repo.id})"
9
- install_dist = repo.backend_service(SmartProxy.pulp_master).backend_data['distributors'].find { |dist| dist['distributor_type_id'] == 'puppet_install_distributor' }
10
- SmartProxy.pulp_master.pulp_api.resources.repository.delete_distributor(repo.pulp_id, install_dist['id'])
11
- ForemanTasks.sync_task(::Actions::Pulp::Repository::Refresh, repo)
8
+ begin
9
+ puts "Refreshing repository #{repo.label} (#{repo.id})"
10
+ install_dist = repo.backend_service(SmartProxy.pulp_master).backend_data['distributors'].find { |dist| dist['distributor_type_id'] == 'puppet_install_distributor' }
11
+ if install_dist
12
+ SmartProxy.pulp_master.pulp_api.resources.repository.delete_distributor(repo.pulp_id, install_dist['id'])
13
+ end
14
+ ForemanTasks.sync_task(::Actions::Pulp::Repository::Refresh, repo)
15
+ rescue RestClient::ResourceNotFound
16
+ Rails.logger.warn("Recieved 404 on repository: #{repo.id} - #{repo.name}")
17
+ next
18
+ end
12
19
  end
13
20
  end
14
21
  end
@@ -1,3 +1,3 @@
1
1
  module Katello
2
- VERSION = "3.11.0.rc1".freeze
2
+ VERSION = "3.11.0.rc2".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: katello
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.11.0.rc1
4
+ version: 3.11.0.rc2
5
5
  platform: ruby
6
6
  authors:
7
7
  - N/A
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-17 00:00:00.000000000 Z
11
+ date: 2019-01-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -176,7 +176,7 @@ dependencies:
176
176
  requirements:
177
177
  - - ">="
178
178
  - !ruby/object:Gem::Version
179
- version: 2.10.0
179
+ version: 2.11.0
180
180
  - - "<"
181
181
  - !ruby/object:Gem::Version
182
182
  version: 3.0.0
@@ -186,7 +186,7 @@ dependencies:
186
186
  requirements:
187
187
  - - ">="
188
188
  - !ruby/object:Gem::Version
189
- version: 2.10.0
189
+ version: 2.11.0
190
190
  - - "<"
191
191
  - !ruby/object:Gem::Version
192
192
  version: 3.0.0