foreman_docker 4.1.0 → 4.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/foreman_docker/version.rb +1 -1
- data/lib/tasks/cleanup.rake +36 -0
- metadata +17 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 43cd7668767c5440916fba9caa6a3167865fea60
|
4
|
+
data.tar.gz: 1f908ee9c8983e0f34a7011bc595a51743fff14e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8367d15c8bb793bcf2e7d98c1ef82a6b45254b80a966d45e422770d6976685663e337842f355d80804f8a4d24be890963a0dab8902ddfad21b192de43df98862
|
7
|
+
data.tar.gz: c363e982dc9849c38eea03865465a083c886c1c1815a5d1aaa35351d727ed021c93b46f36275a0482208879feb4f43951e84c9fe926ed41fad91c0ef54eec455
|
@@ -0,0 +1,36 @@
|
|
1
|
+
namespace :foreman_docker do
|
2
|
+
desc 'Clean default data created by this plugin, this will permanently delete the data!'
|
3
|
+
task :cleanup => :environment do
|
4
|
+
puts 'Cleaning data...'
|
5
|
+
|
6
|
+
User.as_anonymous_admin do
|
7
|
+
puts '... deleting records from taxable_taxonomies'
|
8
|
+
TaxableTaxonomy.where(:taxable_type => [ 'Container', 'DockerRegistry', 'Preliminary', 'ForemanDocker::Docker' ]).delete_all
|
9
|
+
puts '... deleting filters'
|
10
|
+
Filter.joins(:permissions).where('permissions.resource_type' => Foreman::Plugin.find(:foreman_docker).registered_permissions.map { |p, attrs| attrs[:resource_type] }.uniq!).destroy_all
|
11
|
+
puts '... deleting permissions'
|
12
|
+
Permission.where(:name => Foreman::Plugin.find(:foreman_docker).registered_permissions.map(&:first)).destroy_all
|
13
|
+
puts '... deleting docker compute resources'
|
14
|
+
ForemanDocker::Docker.destroy_all
|
15
|
+
puts 'data from all tables deleted'
|
16
|
+
end
|
17
|
+
|
18
|
+
tables = [
|
19
|
+
:containers,
|
20
|
+
:docker_registries,
|
21
|
+
:docker_container_wizard_states,
|
22
|
+
:docker_container_wizard_states_preliminaries,
|
23
|
+
:docker_container_wizard_states_images,
|
24
|
+
:docker_container_wizard_states_configurations,
|
25
|
+
:docker_container_wizard_states_environments,
|
26
|
+
:docker_parameters
|
27
|
+
]
|
28
|
+
tables.each do |table|
|
29
|
+
puts "... dropping table #{table}"
|
30
|
+
ActiveRecord::Migration.drop_table table
|
31
|
+
end
|
32
|
+
|
33
|
+
puts 'Clean up finished, you can now remove the plugin from your system'
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_docker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.
|
4
|
+
version: 4.1.1
|
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:
|
11
|
+
date: 2019-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: docker-api
|
@@ -195,6 +195,7 @@ files:
|
|
195
195
|
- lib/foreman_docker.rb
|
196
196
|
- lib/foreman_docker/engine.rb
|
197
197
|
- lib/foreman_docker/version.rb
|
198
|
+
- lib/tasks/cleanup.rake
|
198
199
|
- lib/tasks/test.rake
|
199
200
|
- locale/Makefile
|
200
201
|
- locale/de/LC_MESSAGES/foreman_docker.mo
|
@@ -261,31 +262,31 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
261
262
|
version: '0'
|
262
263
|
requirements: []
|
263
264
|
rubyforge_project:
|
264
|
-
rubygems_version: 2.6.
|
265
|
+
rubygems_version: 2.6.14.1
|
265
266
|
signing_key:
|
266
267
|
specification_version: 4
|
267
268
|
summary: Provision and manage Docker containers and images from Foreman
|
268
269
|
test_files:
|
269
|
-
- test/factories/compute_resources.rb
|
270
|
-
- test/factories/containers.rb
|
271
|
-
- test/factories/docker_registry.rb
|
272
270
|
- test/functionals/api/v2/containers_controller_test.rb
|
273
271
|
- test/functionals/api/v2/registries_controller_test.rb
|
274
|
-
- test/functionals/containers_steps_controller_test.rb
|
275
|
-
- test/functionals/containers_controller_test.rb
|
276
272
|
- test/functionals/image_search_controller_test.rb
|
277
|
-
- test/
|
273
|
+
- test/functionals/containers_controller_test.rb
|
274
|
+
- test/functionals/containers_steps_controller_test.rb
|
278
275
|
- test/integration/container_steps_test.rb
|
276
|
+
- test/integration/container_test.rb
|
279
277
|
- test/integration/registry_creation_test.rb
|
280
|
-
- test/
|
281
|
-
- test/
|
282
|
-
- test/
|
283
|
-
- test/units/utility_service_test.rb
|
278
|
+
- test/factories/containers.rb
|
279
|
+
- test/factories/docker_registry.rb
|
280
|
+
- test/factories/compute_resources.rb
|
284
281
|
- test/units/container_test.rb
|
285
|
-
- test/units/image_search_service_test.rb
|
286
|
-
- test/units/containers_service_test.rb
|
287
282
|
- test/units/docker_container_wizard_states/image_test.rb
|
288
|
-
- test/units/
|
283
|
+
- test/units/containers_service_test.rb
|
289
284
|
- test/units/registry_api_test.rb
|
285
|
+
- test/units/image_search_service_test.rb
|
286
|
+
- test/units/docker_registry_test.rb
|
287
|
+
- test/units/foreman_docker/compute_resource_extensions_test.rb
|
288
|
+
- test/units/foreman_docker/docker_test.rb
|
289
|
+
- test/units/container_remover_test.rb
|
290
|
+
- test/units/utility_service_test.rb
|
290
291
|
- test/test_plugin_helper.rb
|
291
292
|
- ".rubocop.yml"
|