inprovise-vbox 0.2.10 → 0.2.11

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MmEzN2Y0NWY5MmZjZWZhZjljMzc1Zjg0OWYwMGM2ZTdjZWI2MWJiOA==
4
+ NGIyZmQ5NGMzODVkNzNlZjczMTVhYmJkN2U3OTdlMWQ0NWI5ODhjZA==
5
5
  data.tar.gz: !binary |-
6
- NTcyYjg1NWQ0NTdkMWZkYjQ1OTA5YTdmNWFhZjQ3YzdiNGY1MTE4NA==
6
+ NDI0Y2QzMDRjMTYyOTRhZmFkNDIwY2Y4ZTJhOTM0MDFiNzhhY2U5OA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- OWVlODJiMzJiZjQ0YTFiOTdiZTJmNjE4ODJlYjkzNTYyMWI5YTdhNTc0Mjlj
10
- ZGY0ODcwZjRmMjM1ZTBjOThhM2JkYzBmMWFiOTg1N2U3ZGUxNDYwMGU5ZGYy
11
- YTNjMmQyYTU1OTFhYmI3NjM3ZGE3ODdlYTBkODVmMmFjZGQ1YTA=
9
+ MDMxZThkODUzZDcxMDMwNmY0MTJkMDlkN2I4MjJhZjY1OWZmNGQyNWFmOWMw
10
+ N2NjNTYxYzgxOThmMjA4OGEyYWQ1NjI3MmVmNDUxODA1OGNjOGRmOWQzNTJm
11
+ YjJiY2MwYmNkMzQ4YTI2YWM0ZWUwZTA5Y2M3NDA4YzU1ZTU3NzE=
12
12
  data.tar.gz: !binary |-
13
- ZGUzMzEyM2IzY2RiMDlhNzM0YjhiOGRmNzRkMzNiYTI2Y2Y4NWM2YmU4YjY1
14
- YjBiMWU5Mjk5ZmMwOTA2N2U4NzE1NDYyYzMwZDIxNjkwMjk0OTZiMjI4NTBm
15
- YzQ3OTRhNzlhMjEzYmViNWNhYTQxNzAzMGEyODdlMjg0ZWUwOGE=
13
+ Yjg2MmU1YTYxMzJhYzlmOTQ5OWQzNDRjODdlNjRmOTg2MTAwYTY4ZDdjYWE0
14
+ ODgzOTJjYThmNzIyMWNlNTk4N2FkOGNmYmE0YzNlNmEzNzZmMWYzNTVkZjk4
15
+ M2ExMmNjMmZjMzY3MDk1YjQ4YmMwYjEyMWQxZDUzZjQwMzUyNjc=
@@ -104,6 +104,8 @@ module Inprovise::VBox
104
104
  @configuration[:network] ||= :hostnet
105
105
  # generate name if none set
106
106
  @configuration[:name] ||= "#{name}_#{self.hash}_#{Time.now.to_f}"
107
+ # create default configuration callback
108
+ self.configure
107
109
 
108
110
  vbs = self
109
111
  # define the scripts that do the actual work as dependencies
@@ -278,12 +280,12 @@ module Inprovise::VBox
278
280
  # overload Script#configure
279
281
  def configure(cfg=nil, &definition)
280
282
  @configuration = Inprovise::Config.new.merge!(cfg) if cfg
281
- if block_given?
282
- vbs = self
283
- command(:configure) do
284
- self.instance_eval(&definition)
285
- config['vbox'] = Inprovise::Infrastructure.find(config[vbs.name][:name])
286
- end
283
+ vbs = self
284
+ config_block = block_given? ? definition : nil
285
+ command(:configure).clear
286
+ command(:configure) do
287
+ self.instance_eval(&config_block) if config_block
288
+ config['vbox'] = Inprovise::Infrastructure.find(config[vbs.name][:name])
287
289
  end
288
290
  @configuration
289
291
  end
@@ -5,6 +5,6 @@
5
5
 
6
6
  module Inprovise; module VBox
7
7
 
8
- VERSION = '0.2.10'
8
+ VERSION = '0.2.11'
9
9
 
10
10
  end; end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: inprovise-vbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.10
4
+ version: 0.2.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Corino
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-22 00:00:00.000000000 Z
11
+ date: 2016-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: inprovise