foreman_debian 0.1.0 → 0.1.1

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: 5d6aa19d3ebbd8fe3265eb96870fd7002682c037
4
- data.tar.gz: 2b2ae19872ecea10da5154d4f8b686116b2daa9c
3
+ metadata.gz: 31b97a39895bf6b8730d3577f40f76caf3c2d653
4
+ data.tar.gz: 2fe42c180f1a02bb5458777e2c73b6eb4ba69b5f
5
5
  SHA512:
6
- metadata.gz: 7a83b6b90a4d5728e691e593ee367fc51d24f0d16310d8128340fb82f1d2309bbde0cd8024b67ac151adb2c0bf21ae14458da176032641edba76ea40055a1ad7
7
- data.tar.gz: 2b9ea9fd8c3354e4548ddb3255ffd5385b90ffbc7c61a1409300a7a08c2279f5ba5cb91d5fd8a287bc3912ca96d8d4740ea6db1e00e8c7d8f146a64f6a415500
6
+ metadata.gz: 11d7dc59dd978e495a26a9ea72e79770d8e679c2e13223b00f2f0d5c1bf2097aea76b5014c60385e6b51909ae4e95cbd877afb26488a0f75211f1aa176b96a41
7
+ data.tar.gz: e0086bd5305dcff1d1b0f664e679d13a5a78dd15466c837fe934502fee26028c9d3224e9e3f9d2c15030601b77ec95ce37330564481fcb965cd94cac238ac9f6
@@ -32,7 +32,11 @@ module ForemanDebian
32
32
  def start
33
33
  threads = []
34
34
  each_file do |path|
35
- threads << Thread.new { start_file(path) }
35
+ threads << Thread.new do
36
+ exec_command("#{path.to_s} start")
37
+ @output.info " start #{path.to_s}"
38
+ end
39
+ exec_command("update-rc.d #{path.basename} defaults") if path.dirname.eql? @system_export_path
36
40
  end
37
41
  ThreadsWait.all_waits(*threads)
38
42
  end
@@ -40,23 +44,15 @@ module ForemanDebian
40
44
  def stop
41
45
  threads = []
42
46
  each_file do |path|
43
- threads << Thread.new { stop_file(path) }
47
+ @output.info " stop #{path.to_s}"
48
+ threads << Thread.new do
49
+ exec_command("#{path.to_s} stop")
50
+ end
51
+ exec_command("update-rc.d -f #{path.basename} remove") if path.dirname.eql? @system_export_path
44
52
  end
45
53
  ThreadsWait.all_waits(*threads)
46
54
  end
47
55
 
48
- def start_file(path)
49
- exec_command("#{path.to_s} start")
50
- @output.info " start #{path.to_s}"
51
- exec_command("update-rc.d #{path.basename} defaults") if path.dirname.eql? @system_export_path
52
- end
53
-
54
- def stop_file(path)
55
- exec_command("#{path.to_s} stop")
56
- @output.info " stop #{path.to_s}"
57
- exec_command("update-rc.d -f #{path.basename} remove") if path.dirname.eql? @system_export_path
58
- end
59
-
60
56
  def remove_file(path)
61
57
  stop_file(path)
62
58
  super(path)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_debian
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - cargomedia
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-03-02 00:00:00.000000000 Z
12
+ date: 2015-06-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: clamp
@@ -17,14 +17,14 @@ dependencies:
17
17
  requirements:
18
18
  - - "~>"
19
19
  - !ruby/object:Gem::Version
20
- version: '0.5'
20
+ version: '0.6'
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - "~>"
26
26
  - !ruby/object:Gem::Version
27
- version: '0.5'
27
+ version: '0.6'
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: foreman
30
30
  requirement: !ruby/object:Gem::Requirement
@@ -125,7 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  version: '0'
126
126
  requirements: []
127
127
  rubyforge_project:
128
- rubygems_version: 2.2.2
128
+ rubygems_version: 2.4.6
129
129
  signing_key:
130
130
  specification_version: 4
131
131
  summary: Foreman wrapper for debian