foreman_docker 4.1.1 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 43cd7668767c5440916fba9caa6a3167865fea60
4
- data.tar.gz: 1f908ee9c8983e0f34a7011bc595a51743fff14e
3
+ metadata.gz: c5ac730e6148dbc864993904f675d5ce39c006eb
4
+ data.tar.gz: aa06eac3042c65430165f088215a74842722ce80
5
5
  SHA512:
6
- metadata.gz: 8367d15c8bb793bcf2e7d98c1ef82a6b45254b80a966d45e422770d6976685663e337842f355d80804f8a4d24be890963a0dab8902ddfad21b192de43df98862
7
- data.tar.gz: c363e982dc9849c38eea03865465a083c886c1c1815a5d1aaa35351d727ed021c93b46f36275a0482208879feb4f43951e84c9fe926ed41fad91c0ef54eec455
6
+ metadata.gz: 5ea694ca1bce470fb8f52e935cdad83b0e35b7781dc0c1f943cc2f282f1d5a3836b78c9c663e4e540aa9e5d292f360ea1c215cd6edfb03c6ec367c167cc5c004
7
+ data.tar.gz: 30e37c18f1e34fceef34f9a4a0e277aa974aef96f4b9bfb87f9e9ebf07b20cfb378697e00de37162aaa9fc32b93ea4ba87ac21d05529634412eaf4734348ad5b
data/README.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Foreman Docker Plugin
2
2
 
3
+ **This plugin has been discontinued. The latest release only helps with its removal. If you're interested in taking over the maintanance, let us know.**
4
+
5
+ In order to remove the plugin from you Foreman installation, following steps need to be taken
6
+
7
+ 1. make a backup
8
+ 1. upgrade to last version of foreman-docker 5.0 (and Katello if you're using it)
9
+ 1. run `foreman-rake db:migrate` (if you have Katello, this will erase docker data)
10
+ 1. run `foreman-rake foreman_docker:cleanup` (cleans up all data that this plugin introduced)
11
+ 1. `yum remove tfm-rubygem-foreman_docker` or `apt remove ruby-foreman-docker`
12
+ 1. `yum remove tfm-rubygem-hammer_cli_foreman_docker` or `apt remove ruby-hammer-cli-foreman-docker` unless you still use katello commands from it
13
+ 1. update apipie cache `foreman-rake apipie:cache`
14
+ 1. `service httpd restart`
15
+
16
+
3
17
  [![Code Climate](https://codeclimate.com/github/theforeman/foreman-docker/badges/gpa.svg)](https://codeclimate.com/github/theforeman/foreman-docker)
4
18
  [![Gem Version](https://badge.fury.io/rb/foreman_docker.svg)](http://badge.fury.io/rb/foreman_docker)
5
19
  [![Dependency Status](https://gemnasium.com/theforeman/foreman-docker.svg)](https://gemnasium.com/theforeman/foreman-docker)
@@ -1,8 +1,8 @@
1
- require 'fast_gettext'
2
- require 'gettext_i18n_rails'
3
- require 'fog/fogdocker'
1
+ #require 'fast_gettext'
2
+ #require 'gettext_i18n_rails'
3
+ #require 'fog/fogdocker'
4
4
  require 'wicked'
5
- require 'docker'
5
+ #require 'docker'
6
6
  require 'deface'
7
7
 
8
8
  module ForemanDocker
@@ -20,131 +20,131 @@ module ForemanDocker
20
20
  end
21
21
  end
22
22
 
23
- foreman_docker_assets = %w[foreman_docker/autocomplete.css
24
- foreman_docker/terminal.css
25
- foreman_docker/container_image_search.js
26
- foreman_docker/create_registry.js]
27
-
28
- initializer "foreman_docker.assets.precompile" do |app|
29
- app.config.assets.precompile += foreman_docker_assets
30
- end
31
-
32
- initializer 'foreman_docker.configure_assets', :group => :assets do
33
- SETTINGS[:foreman_docker] =
34
- { :assets => { :precompile => foreman_docker_assets } }
35
- end
36
-
37
- initializer 'foreman_docker.register_gettext', :after => :load_config_initializers do
38
- locale_dir = File.join(File.expand_path('../../..', __FILE__), 'locale')
39
- locale_domain = 'foreman_docker'
40
-
41
- Foreman::Gettext::Support.add_text_domain locale_domain, locale_dir
42
- end
23
+ # foreman_docker_assets = %w[foreman_docker/autocomplete.css
24
+ # foreman_docker/terminal.css
25
+ # foreman_docker/container_image_search.js
26
+ # foreman_docker/create_registry.js]
27
+
28
+ # initializer "foreman_docker.assets.precompile" do |app|
29
+ # app.config.assets.precompile += foreman_docker_assets
30
+ # end
31
+
32
+ # initializer 'foreman_docker.configure_assets', :group => :assets do
33
+ # SETTINGS[:foreman_docker] =
34
+ # { :assets => { :precompile => foreman_docker_assets } }
35
+ # end
36
+ #
37
+ # initializer 'foreman_docker.register_gettext', :after => :load_config_initializers do
38
+ # locale_dir = File.join(File.expand_path('../../..', __FILE__), 'locale')
39
+ # locale_domain = 'foreman_docker'
40
+ #
41
+ # Foreman::Gettext::Support.add_text_domain locale_domain, locale_dir
42
+ # end
43
43
 
44
44
  initializer 'foreman_docker.register_plugin', :before => :finisher_hook do
45
45
  Foreman::Plugin.register :foreman_docker do
46
46
  requires_foreman '>= 1.15'
47
47
  compute_resource ForemanDocker::Docker
48
48
 
49
- sub_menu :top_menu, :containers_menu, :caption => N_('Containers'),
50
- :icon => 'fa fa-cube',
51
- :after => :monitor_menu do
52
- menu :top_menu, :containers, :caption => N_('All Containers'),
53
- :url_hash => { :controller => :containers,
54
- :action => :index }
55
- menu :top_menu, :new_container, :caption => N_('Create Container'),
56
- :url_hash => { :controller => :containers,
57
- :action => :new }
58
- menu :top_menu, :registries, :caption => N_('Registries'),
59
- :url_hash => { :controller => :registries,
60
- :action => :index }
61
- end
62
-
63
- security_block :containers do
64
- permission :view_containers,
65
- { :containers => [:index, :show],
66
- :'api/v2/containers' => [:index, :show, :logs] },
67
- :resource_type => 'Container'
68
- permission :commit_containers, { :containers => [:commit] },
69
- :resource_type => 'Container'
70
- permission :create_containers,
71
- { :'containers/steps' => [:show, :update],
72
- :containers => [:new],
73
- :'api/v2/containers' => [:create, :power] },
74
- :resource_type => 'Container'
75
- permission :destroy_containers,
76
- { :containers => [:destroy],
77
- :'api/v2/containers' => [:destroy] },
78
- :resource_type => 'Container'
79
- permission :power_compute_resources_vms,
80
- { :containers => [:power],
81
- :'api/v2/containers' => [:create, :power] },
82
- :resource_type => 'ComputeResource'
83
- end
84
-
85
- security_block :registries do
86
- permission :view_registries,
87
- { :registries => [:index, :show],
88
- :'api/v2/registries' => [:index, :show] },
89
- :resource_type => 'DockerRegistry'
90
- permission :create_registries,
91
- { :registries => [:new, :create, :update, :edit],
92
- :'api/v2/registries' => [:create, :update] },
93
- :resource_type => 'DockerRegistry'
94
- permission :destroy_registries,
95
- { :registries => [:destroy],
96
- :'api/v2/registries' => [:destroy] },
97
- :resource_type => 'DockerRegistry'
98
- end
99
-
100
- security_block :image_search do
101
- permission :search_repository_image_search,
102
- { :image_search => [:auto_complete_repository_name,
103
- :auto_complete_image_tag,
104
- :search_repository] },
105
- :resource_type => 'DockerRegistry'
106
- end
107
-
108
- add_all_permissions_to_default_roles
49
+ # sub_menu :top_menu, :containers_menu, :caption => N_('Containers'),
50
+ # :icon => 'fa fa-cube',
51
+ # :after => :monitor_menu do
52
+ # menu :top_menu, :containers, :caption => N_('All Containers'),
53
+ # :url_hash => { :controller => :containers,
54
+ # :action => :index }
55
+ # menu :top_menu, :new_container, :caption => N_('Create Container'),
56
+ # :url_hash => { :controller => :containers,
57
+ # :action => :new }
58
+ # menu :top_menu, :registries, :caption => N_('Registries'),
59
+ # :url_hash => { :controller => :registries,
60
+ # :action => :index }
61
+ # end
62
+ #
63
+ # security_block :containers do
64
+ # permission :view_containers,
65
+ # { :containers => [:index, :show],
66
+ # :'api/v2/containers' => [:index, :show, :logs] },
67
+ # :resource_type => 'Container'
68
+ # permission :commit_containers, { :containers => [:commit] },
69
+ # :resource_type => 'Container'
70
+ # permission :create_containers,
71
+ # { :'containers/steps' => [:show, :update],
72
+ # :containers => [:new],
73
+ # :'api/v2/containers' => [:create, :power] },
74
+ # :resource_type => 'Container'
75
+ # permission :destroy_containers,
76
+ # { :containers => [:destroy],
77
+ # :'api/v2/containers' => [:destroy] },
78
+ # :resource_type => 'Container'
79
+ # permission :power_compute_resources_vms,
80
+ # { :containers => [:power],
81
+ # :'api/v2/containers' => [:create, :power] },
82
+ # :resource_type => 'ComputeResource'
83
+ # end
84
+ #
85
+ # security_block :registries do
86
+ # permission :view_registries,
87
+ # { :registries => [:index, :show],
88
+ # :'api/v2/registries' => [:index, :show] },
89
+ # :resource_type => 'DockerRegistry'
90
+ # permission :create_registries,
91
+ # { :registries => [:new, :create, :update, :edit],
92
+ # :'api/v2/registries' => [:create, :update] },
93
+ # :resource_type => 'DockerRegistry'
94
+ # permission :destroy_registries,
95
+ # { :registries => [:destroy],
96
+ # :'api/v2/registries' => [:destroy] },
97
+ # :resource_type => 'DockerRegistry'
98
+ # end
99
+ #
100
+ # security_block :image_search do
101
+ # permission :search_repository_image_search,
102
+ # { :image_search => [:auto_complete_repository_name,
103
+ # :auto_complete_image_tag,
104
+ # :search_repository] },
105
+ # :resource_type => 'DockerRegistry'
106
+ # end
107
+ #
108
+ # add_all_permissions_to_default_roles
109
109
 
110
110
  parameter_filter ComputeResource, :email
111
111
 
112
- # apipie API documentation
113
- # Only available in 1.8, otherwise it has to be in the initializer below
114
- if SETTINGS[:version].to_s.include?('develop') ||
115
- Gem::Version.new(SETTINGS[:version].notag) >= Gem::Version.new('1.8')
116
- apipie_documented_controllers [
117
- "#{ForemanDocker::Engine.root}/app/controllers/api/v2/*.rb"]
118
- end
119
- end
120
- end
121
-
122
- initializer "foreman_docker.apipie" do
123
- # this condition is here for compatibility reason to work with Foreman 1.4.x
124
- # Also need to handle the reverse of the 1.8 method above
125
- unless SETTINGS[:version].to_s.include?('develop') ||
126
- Gem::Version.new(SETTINGS[:version].notag) >= Gem::Version.new('1.8')
127
- if Apipie.configuration.api_controllers_matcher.is_a?(Array)
128
- Apipie.configuration.api_controllers_matcher <<
129
- "#{ForemanDocker::Engine.root}/app/controllers/api/v2/*.rb"
130
- end
112
+ # # apipie API documentation
113
+ # # Only available in 1.8, otherwise it has to be in the initializer below
114
+ # if SETTINGS[:version].to_s.include?('develop') ||
115
+ # Gem::Version.new(SETTINGS[:version].notag) >= Gem::Version.new('1.8')
116
+ # apipie_documented_controllers [
117
+ # "#{ForemanDocker::Engine.root}/app/controllers/api/v2/*.rb"]
118
+ # end
131
119
  end
132
120
  end
133
121
 
134
- require 'fog/fogdocker/models/compute/server'
135
- require 'fog/fogdocker/models/compute/image'
136
- require 'fog/fogdocker/models/compute/images'
137
- require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/server',
138
- __FILE__)
139
- require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/image',
140
- __FILE__)
141
- require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/images',
142
- __FILE__)
122
+ # initializer "foreman_docker.apipie" do
123
+ # # this condition is here for compatibility reason to work with Foreman 1.4.x
124
+ # # Also need to handle the reverse of the 1.8 method above
125
+ # unless SETTINGS[:version].to_s.include?('develop') ||
126
+ # Gem::Version.new(SETTINGS[:version].notag) >= Gem::Version.new('1.8')
127
+ # if Apipie.configuration.api_controllers_matcher.is_a?(Array)
128
+ # Apipie.configuration.api_controllers_matcher <<
129
+ # "#{ForemanDocker::Engine.root}/app/controllers/api/v2/*.rb"
130
+ # end
131
+ # end
132
+ # end
133
+
134
+ # require 'fog/fogdocker/models/compute/server'
135
+ # require 'fog/fogdocker/models/compute/image'
136
+ # require 'fog/fogdocker/models/compute/images'
137
+ # require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/server',
138
+ # __FILE__)
139
+ # require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/image',
140
+ # __FILE__)
141
+ # require File.expand_path('../../../app/models/concerns/fog_extensions/fogdocker/images',
142
+ # __FILE__)
143
143
  config.to_prepare do
144
- Fog::Compute::Fogdocker::Server.send(:include, ::FogExtensions::Fogdocker::Server)
145
- Fog::Compute::Fogdocker::Image.send(:include, ::FogExtensions::Fogdocker::Image)
146
- # Compatibility fixes - to be removed once 1.7 compatibility is no longer required
147
- Fog::Compute::Fogdocker::Images.send(:include, ::FogExtensions::Fogdocker::Images)
144
+ # Fog::Compute::Fogdocker::Server.send(:include, ::FogExtensions::Fogdocker::Server)
145
+ # Fog::Compute::Fogdocker::Image.send(:include, ::FogExtensions::Fogdocker::Image)
146
+ # # Compatibility fixes - to be removed once 1.7 compatibility is no longer required
147
+ # Fog::Compute::Fogdocker::Images.send(:include, ::FogExtensions::Fogdocker::Images)
148
148
  ::Taxonomy.send(:include, ForemanDocker::TaxonomyExtensions)
149
149
  ComputeResource.send(:include, ForemanDocker::ComputeResourceExtensions)
150
150
  end
@@ -1,3 +1,3 @@
1
1
  module ForemanDocker
2
- VERSION = '4.1.1'
2
+ VERSION = '5.0.0'
3
3
  end
metadata CHANGED
@@ -1,43 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_docker
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.1
4
+ version: 5.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Lobato, Amos Benari
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-02-26 00:00:00.000000000 Z
11
+ date: 2019-03-20 00:00:00.000000000 Z
12
12
  dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: docker-api
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '1.18'
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '1.18'
27
- - !ruby/object:Gem::Dependency
28
- name: excon
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - "~>"
32
- - !ruby/object:Gem::Version
33
- version: '0.46'
34
- type: :runtime
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - "~>"
39
- - !ruby/object:Gem::Version
40
- version: '0.46'
41
13
  - !ruby/object:Gem::Dependency
42
14
  name: deface
43
15
  requirement: !ruby/object:Gem::Requirement
@@ -80,7 +52,8 @@ dependencies:
80
52
  - - '='
81
53
  - !ruby/object:Gem::Version
82
54
  version: 0.52.0
83
- description: Provision and manage Docker containers and images from Foreman.
55
+ description: This version does not provide any functionality and only makes plugin
56
+ removal easier.
84
57
  email:
85
58
  - dlobatog@redhat.com, abenari@redhat.com
86
59
  executables: []
@@ -265,7 +238,8 @@ rubyforge_project:
265
238
  rubygems_version: 2.6.14.1
266
239
  signing_key:
267
240
  specification_version: 4
268
- summary: Provision and manage Docker containers and images from Foreman
241
+ summary: This version does not provide any functionality and only makes plugin removal
242
+ easier.
269
243
  test_files:
270
244
  - test/functionals/api/v2/containers_controller_test.rb
271
245
  - test/functionals/api/v2/registries_controller_test.rb