testlab 1.22.3 → 1.22.4
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 +8 -8
- data/lib/testlab/container/status.rb +9 -0
- data/lib/testlab/provisioners/hosts_file.rb +2 -2
- data/lib/testlab/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZDI5MmViZWZmMjk3NjY2NTA3ZDI4ZDMzMTExY2RhYjBkMTZkODUxYg==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NWRkN2JhZDc2NGZiZTVlZWIxNjNhYzY0ZDBhZDc5MzI2YjIzNTNlYw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ZTdjOWI1NWI1YzdiMTBmYWJkNzQ4MGNiZWZmYmMxNzU1ZWQ1YmQxYzE0M2Vi
|
10
|
+
MGQ3NjdiNmE2MTU0ZmNlYzc0OGJlOGUzZjY2MWI1ZGNlODBmNDc4Y2MzMThl
|
11
|
+
YjA3Y2NmMGEzM2Y3MTYxMWUzZjY2OGQ5ODM5ZjI4NDdjNzA3ZTU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZjlmNDA0MjIzM2MyYTgxOGRlN2M5Zjg2MWM2MDc3M2ZiNDdkMWYyMzJlZTcw
|
14
|
+
ZDIyN2U3NzM0ZWU3MTlmMmNiZThjODAzZTFlYzM5YTM4NDFmNjRjODk0MWE3
|
15
|
+
ZmFkZmRkOGUwNDI1MGQ4OTA3NjVhMGJjMGRkZjlmYzFkMjljODc=
|
@@ -41,6 +41,15 @@ class TestLab
|
|
41
41
|
[self.id, self.domain].join('.')
|
42
42
|
end
|
43
43
|
|
44
|
+
# Container Alive?
|
45
|
+
#
|
46
|
+
# Is the container alive and running?
|
47
|
+
#
|
48
|
+
# @return [Boolean] True if the container is running; False otherwise.
|
49
|
+
def alive?
|
50
|
+
(self.state == :running)
|
51
|
+
end
|
52
|
+
|
44
53
|
# Container Status
|
45
54
|
#
|
46
55
|
# Returns a hash of status information for the container.
|
@@ -50,12 +50,12 @@ EOI
|
|
50
50
|
command = %(/bin/bash -x #{tempfile.path})
|
51
51
|
|
52
52
|
@command.exec(command)
|
53
|
-
container.bootstrap(script)
|
53
|
+
container.alive? and container.bootstrap(script)
|
54
54
|
end
|
55
55
|
|
56
56
|
def remove_hosts(container)
|
57
57
|
@command.exec(sed_hostsfile)
|
58
|
-
container.exec(sed_hostsfile('linux'))
|
58
|
+
container.alive? and container.exec(sed_hostsfile('linux'))
|
59
59
|
end
|
60
60
|
|
61
61
|
def hosts_blob(container)
|
data/lib/testlab/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: testlab
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.22.
|
4
|
+
version: 1.22.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Zachary Patten
|
@@ -390,7 +390,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
390
390
|
version: '0'
|
391
391
|
requirements: []
|
392
392
|
rubyforge_project:
|
393
|
-
rubygems_version: 2.
|
393
|
+
rubygems_version: 2.1.11
|
394
394
|
signing_key:
|
395
395
|
specification_version: 4
|
396
396
|
summary: A toolkit for building virtual computer labs
|