chef-provisioning-opennebula 0.4.3 → 0.4.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 +4 -4
- data/README.md +8 -18
- data/lib/chef/provider/one_template.rb +19 -3
- data/lib/chef/provisioning/opennebula_driver/one_lib.rb +11 -4
- data/lib/chef/provisioning/opennebula_driver/version.rb +1 -1
- data/spec/config_sample.rb +60 -0
- data/spec/integration/test_all_integration_spec.rb +264 -79
- data/spec/recipes/OneDriver/attach_back_one_vm_spec.rb +20 -0
- data/spec/recipes/OneDriver/attach_back_two_vm_spec.rb +20 -0
- data/spec/recipes/OneDriver/attach_one_image_spec.rb +20 -0
- data/spec/recipes/OneDriver/converge_back_one_vm_spec.rb +19 -0
- data/spec/recipes/OneDriver/converge_back_two_vm_spec.rb +19 -0
- data/spec/recipes/OneDriver/converge_bootstrap_vm_spec.rb +26 -0
- data/spec/recipes/OneDriver/create_back_one_vm_spec.rb +20 -0
- data/spec/recipes/OneDriver/create_back_two_vm_spec.rb +20 -0
- data/spec/recipes/OneDriver/create_bootstrap_vm_spec.rb +26 -0
- data/spec/recipes/OneDriver/create_one_image_spec.rb +23 -0
- data/spec/recipes/OneDriver/create_one_template_int_spec.rb +21 -0
- data/spec/recipes/OneDriver/create_one_template_spec.rb +21 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-back-1-vm.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-back-2-vm.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-bootstrap-img.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-bootstrap-vm.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-snap-1-img.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-snap-2-img.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-test-tpl-ints.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-test-tpl.rb +19 -0
- data/spec/recipes/OneDriver/delete/OpenNebula-tpl-1-vm.rb +19 -0
- data/spec/recipes/OneDriver/instantiate_one_template_spec.rb +25 -0
- data/spec/recipes/OneDriver/snapshot_one_image_spec.rb +21 -0
- data/spec/recipes/OneDriver/snapshot_two_image_spec.rb +21 -0
- data/spec/recipes/driver_options_spec.rb +19 -62
- data/spec/spec_helper.rb +42 -14
- data/spec/support/opennebula_support.rb +69 -34
- metadata +27 -17
- data/spec/recipes/attach_back_one_vm_spec.rb +0 -20
- data/spec/recipes/attach_back_two_vm_spec.rb +0 -20
- data/spec/recipes/attach_one_image_spec.rb +0 -20
- data/spec/recipes/converge_back_one_vm_spec.rb +0 -19
- data/spec/recipes/converge_back_two_vm_spec.rb +0 -19
- data/spec/recipes/converge_bootstrap_vm_spec.rb +0 -34
- data/spec/recipes/create_back_one_vm_spec.rb +0 -20
- data/spec/recipes/create_back_two_vm_spec.rb +0 -20
- data/spec/recipes/create_bootstrap_vm_spec.rb +0 -34
- data/spec/recipes/create_one_image_spec.rb +0 -21
- data/spec/recipes/create_one_template_spec.rb +0 -52
- data/spec/recipes/delete_all_spec.rb +0 -47
- data/spec/recipes/instantiate_one_template_spec.rb +0 -35
- data/spec/recipes/snapshot_one_image_spec.rb +0 -21
- data/spec/recipes/snapshot_two_image_spec.rb +0 -21
@@ -0,0 +1,25 @@
|
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'chef/provisioning/opennebula_driver'
|
16
|
+
require "#{File.dirname(__FILE__)}/../../config.rb"
|
17
|
+
|
18
|
+
machine 'OpenNebula-tpl-1-vm' do
|
19
|
+
machine_options MACHINE_OPTIONS.merge(
|
20
|
+
:bootstrap_options => {
|
21
|
+
:template_name => 'OpenNebula-test-tpl'
|
22
|
+
}
|
23
|
+
)
|
24
|
+
run_list []
|
25
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'chef/provisioning/opennebula_driver'
|
16
|
+
|
17
|
+
one_image 'OpenNebula-snap-1-img' do
|
18
|
+
machine_id 'OpenNebula-bootstrap-vm'
|
19
|
+
disk_id 'OpenNebula-bootstrap-img'
|
20
|
+
action :snapshot
|
21
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
|
+
#
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
|
+
#
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
#
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
|
+
|
15
|
+
require 'chef/provisioning/opennebula_driver'
|
16
|
+
|
17
|
+
one_image 'OpenNebula-snap-2-img' do
|
18
|
+
machine_id 'OpenNebula-bootstrap-vm'
|
19
|
+
disk_id 'OpenNebula-bootstrap-img'
|
20
|
+
action :snapshot
|
21
|
+
end
|
@@ -1,70 +1,27 @@
|
|
1
|
-
# Copyright
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
2
|
#
|
3
|
-
#Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
#you may not use this file except in compliance with the License.
|
5
|
-
#You may obtain a copy of the License at
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
6
|
#
|
7
7
|
# http://www.apache.org/licenses/LICENSE-2.0
|
8
8
|
#
|
9
|
-
#Unless required by applicable law or agreed to in writing, software
|
10
|
-
#distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
#See the License for the specific language governing permissions and
|
13
|
-
#limitations under the License.
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
14
|
|
15
15
|
require 'chef/provisioning/opennebula_driver'
|
16
|
+
require 'fileutils'
|
17
|
+
require "#{File.dirname(__FILE__)}/../config.rb"
|
16
18
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
httpbase = "#{ENV['ONE_HTTPBASE']}".dup
|
21
|
-
chef_repo_path = "#{ENV['CHEF_REPO_PATH']}".dup
|
19
|
+
FileUtils.mkdir_p(CHEF_REPO_PATH.chomp('/'))
|
20
|
+
with_chef_local_server :chef_repo_path => CHEF_REPO_PATH.chomp('/')
|
21
|
+
with_driver((ONE_XMLRPC[0, 11] == 'opennebula:' ? ONE_XMLRPC : 'opennebula:' + ONE_XMLRPC).chomp('/'))
|
22
22
|
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
"HTTPBASE" => "#{httpbase}",
|
29
|
-
"MEMORY" => "2048",
|
30
|
-
"CPU" => "1",
|
31
|
-
"VCPU" => "1",
|
32
|
-
"OS" => {
|
33
|
-
"ARCH" => "x86_64"
|
34
|
-
},
|
35
|
-
"DISK" => {
|
36
|
-
"IMAGE" => "Ubuntu-12.04.5-pre-prod-20141216",
|
37
|
-
"IMAGE_UNAME" => "m_plumb",
|
38
|
-
"DRIVER" => "qcow2"
|
39
|
-
},
|
40
|
-
"NIC" => {
|
41
|
-
"NETWORK" => "PUB-52-10.236",
|
42
|
-
"NETWORK_UNAME" => "neutrino"
|
43
|
-
},
|
44
|
-
"GRAPHICS" => {
|
45
|
-
"LISTEN" => "0.0.0.0",
|
46
|
-
"TYPE" => "vnc"
|
47
|
-
},
|
48
|
-
"CONTEXT" => {
|
49
|
-
"NETWORK" => "YES",
|
50
|
-
"HOSTNAME" => "$NAME",
|
51
|
-
"INSTALL_CHEF_CLIENT_COMMAND" => "dpkg -E -i /mnt/chef-client.deb",
|
52
|
-
"SSH_USER" => 'local',
|
53
|
-
"SSH_PUBLIC_KEY" => File.read("#{home}/.ssh/id_rsa.pub").strip,
|
54
|
-
"FILES" => "$HTTPBASE/01_chef $HTTPBASE/../chef-client.deb"
|
55
|
-
}
|
56
|
-
}
|
57
|
-
},
|
58
|
-
:ssh_user => 'local',
|
59
|
-
:ssh_options => {
|
60
|
-
:keys_only => false,
|
61
|
-
:forward_agent => true,
|
62
|
-
:use_agent => true,
|
63
|
-
:user_known_hosts_file => '/dev/null'
|
64
|
-
},
|
65
|
-
:ssh_execute_options => {
|
66
|
-
:prefix => 'sudo '
|
67
|
-
},
|
68
|
-
:cached_installer => true
|
69
|
-
|
70
|
-
with_chef_local_server :chef_repo_path => "#{chef_repo_path}"
|
23
|
+
with_machine_options MACHINE_OPTIONS.merge(
|
24
|
+
:bootstrap_options => {
|
25
|
+
:template => VM_TEMPLATE
|
26
|
+
}
|
27
|
+
)
|
data/spec/spec_helper.rb
CHANGED
@@ -1,16 +1,16 @@
|
|
1
|
-
# Copyright
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
2
|
#
|
3
|
-
#Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
#you may not use this file except in compliance with the License.
|
5
|
-
#You may obtain a copy of the License at
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
6
|
#
|
7
7
|
# http://www.apache.org/licenses/LICENSE-2.0
|
8
8
|
#
|
9
|
-
#Unless required by applicable law or agreed to in writing, software
|
10
|
-
#distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
#See the License for the specific language governing permissions and
|
13
|
-
#limitations under the License.
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
14
|
|
15
15
|
require 'chef/dsl/recipe'
|
16
16
|
require 'chef/mixin/shell_out'
|
@@ -21,15 +21,43 @@ require 'chef/run_context'
|
|
21
21
|
require 'cheffish/rspec/matchers'
|
22
22
|
require 'opennebula'
|
23
23
|
require 'support/opennebula_support'
|
24
|
+
require 'fileutils'
|
25
|
+
|
26
|
+
def test_helper(context, recipe, expected, error = nil)
|
27
|
+
context context do
|
28
|
+
it { is_expected.to converge_test_recipe(recipe, expected, error) }
|
29
|
+
end
|
30
|
+
context "[SKIP] #{context}" do
|
31
|
+
it { is_expected.to converge_test_recipe(recipe, :idempotent, error) }
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
def cleanup
|
36
|
+
chef_run(%w(
|
37
|
+
OneDriver/delete/OpenNebula-test-tpl.rb
|
38
|
+
OneDriver/delete/OpenNebula-test-tpl-ints.rb
|
39
|
+
OneDriver/delete/OpenNebula-tpl-1-vm.rb
|
40
|
+
OneDriver/delete/OpenNebula-bootstrap-vm.rb
|
41
|
+
OneDriver/delete/OpenNebula-bootstrap-img.rb
|
42
|
+
OneDriver/delete/OpenNebula-back-1-vm.rb
|
43
|
+
OneDriver/delete/OpenNebula-back-2-vm.rb
|
44
|
+
OneDriver/delete/OpenNebula-snap-1-img.rb
|
45
|
+
OneDriver/delete/OpenNebula-snap-2-img.rb
|
46
|
+
))
|
47
|
+
end
|
24
48
|
|
25
49
|
RSpec.configure do |config|
|
26
50
|
config.run_all_when_everything_filtered = true
|
27
51
|
config.filter_run :focus
|
52
|
+
config.add_setting :log_dir, :default => "test-results/#{Time.now.strftime('%Y%m%d_%H%M%S')}"
|
28
53
|
config.before(:suite) do
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
54
|
+
FileUtils.rm_rf(config.log_dir)
|
55
|
+
FileUtils.mkdir_p(config.log_dir)
|
56
|
+
FileUtils.rm_rf('nodes')
|
57
|
+
fail 'Quick cleanup before testing failed.' unless cleanup.include?('Chef Client finished')
|
58
|
+
end
|
59
|
+
config.after(:suite) do
|
60
|
+
FileUtils.rm_rf('nodes')
|
61
|
+
fail 'Quick cleanup after testing failed.' unless cleanup.include?('Chef Client finished')
|
34
62
|
end
|
35
63
|
end
|
@@ -1,64 +1,99 @@
|
|
1
|
-
# Copyright
|
1
|
+
# Copyright 2016, BlackBerry, Inc.
|
2
2
|
#
|
3
|
-
#Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
#you may not use this file except in compliance with the License.
|
5
|
-
#You may obtain a copy of the License at
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
# you may not use this file except in compliance with the License.
|
5
|
+
# You may obtain a copy of the License at
|
6
6
|
#
|
7
7
|
# http://www.apache.org/licenses/LICENSE-2.0
|
8
8
|
#
|
9
|
-
#Unless required by applicable law or agreed to in writing, software
|
10
|
-
#distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
#See the License for the specific language governing permissions and
|
13
|
-
#limitations under the License.
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
# See the License for the specific language governing permissions and
|
13
|
+
# limitations under the License.
|
14
14
|
|
15
15
|
require 'cheffish/rspec/chef_run_support'
|
16
16
|
require 'cheffish/rspec/matchers'
|
17
17
|
require 'chef/provisioning/opennebula_driver'
|
18
|
+
require 'fileutils'
|
18
19
|
|
19
20
|
def chef_run(recipe)
|
20
|
-
|
21
|
+
recipe_array = recipe.is_a?(Array) ? recipe : [recipe]
|
22
|
+
chef_client = Mixlib::ShellOut.new(
|
23
|
+
"bundle exec chef-client -z ./spec/recipes/driver_options_spec.rb #{recipe_array.map { |r| './spec/recipes/' + r }.join(' ')} --force-formatter",
|
24
|
+
shellout_options(:timeout => 900)
|
25
|
+
)
|
21
26
|
chef_client.run_command
|
22
27
|
chef_client.stdout
|
23
28
|
end
|
24
29
|
|
25
30
|
def shellout_options(options = {})
|
26
|
-
|
27
|
-
default_options.merge(options)
|
31
|
+
{ :live_stream => STDOUT }.merge(options)
|
28
32
|
end
|
29
33
|
|
30
|
-
def
|
31
|
-
|
34
|
+
def format_error(msg)
|
35
|
+
"================================================================================\n#{msg}\n================================================================================"
|
32
36
|
end
|
33
37
|
|
34
|
-
#
|
35
|
-
def
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
38
|
+
# gets runtime / idempotency-related errors from stdout
|
39
|
+
def get_error(stdout, expected = nil, error = nil)
|
40
|
+
err = stdout.include?('Chef Client finished') ? nil : "Chef run did not report 'Chef Client finished', no errors were detected."
|
41
|
+
|
42
|
+
unless error.nil?
|
43
|
+
case error
|
44
|
+
when Regexp
|
45
|
+
return "stdout matched:\n#{error}" if stdout =~ error
|
46
|
+
when String
|
47
|
+
return "stdout included:\n#{error}" if stdout.include?(error)
|
48
|
+
end
|
40
49
|
end
|
41
|
-
|
42
|
-
if
|
43
|
-
|
44
|
-
|
45
|
-
|
50
|
+
|
51
|
+
if stdout.include?('RuntimeError: ')
|
52
|
+
return "RuntimeError\n" + (stdout.split('RuntimeError: ').last).split("\n").first
|
53
|
+
elsif stdout.include?('NoMethodError: ')
|
54
|
+
return "NoMethodError\n" + (stdout.split('NoMethodError: ').last).split("\n").first
|
55
|
+
elsif stdout.include?('ERROR: ') && err
|
56
|
+
return "ERROR\n" + (stdout.split('ERROR: ').last).split("\n").first
|
57
|
+
elsif stdout.include?('FATAL: ')
|
58
|
+
return "FATAL\nAn unknown fatal error has occurred."
|
46
59
|
end
|
47
|
-
|
60
|
+
|
61
|
+
return err if expected.nil?
|
62
|
+
|
63
|
+
case expected
|
64
|
+
when Symbol
|
65
|
+
fail "The only symbol supported for 'expected' is :idempotent, you passed :#{expected}" unless expected == :idempotent
|
66
|
+
return 'Chef run did not idempotently skip when it should have.' unless stdout.include?('(up to date)')
|
67
|
+
when Regexp
|
68
|
+
return "Chef run idempotently skipped when it should not have.\nIf you intended for it to skip, pass in :idempotent as 'expected' instead." if stdout.include?('(up to date)')
|
69
|
+
return "No match in stdout for:\n#{expected}" unless stdout =~ expected
|
70
|
+
when String
|
71
|
+
return "Chef run idempotently skipped when it should not have.\nIf you intended for it to skip, pass in :idempotent as 'expected' instead." if stdout.include?('(up to date)')
|
72
|
+
return "stdout did not include:\n#{expected}" unless stdout.include?(expected)
|
73
|
+
end
|
74
|
+
|
75
|
+
err
|
48
76
|
end
|
49
77
|
|
50
|
-
RSpec::Matchers.define :
|
51
|
-
|
78
|
+
RSpec::Matchers.define :converge_test_recipe do |recipe = nil, expected = :idempotent, error = nil|
|
79
|
+
fail 'All tests require a recipe.' if recipe.nil?
|
80
|
+
match do
|
52
81
|
stdout = chef_run(recipe)
|
53
82
|
# logs each chef run
|
54
|
-
|
55
|
-
|
83
|
+
dir = RSpec.configuration.log_dir + '/' + File.dirname(recipe)
|
84
|
+
FileUtils.mkdir_p(dir)
|
85
|
+
log_basename = expected == :idempotent ? File.basename(recipe, '.*') + '__i' : File.basename(recipe, '.*')
|
86
|
+
File.open("./#{dir}/#{log_basename}_stdout.log", 'w+') { |file| file.write(stdout) }
|
87
|
+
@error_message = get_error(stdout, expected, error)
|
88
|
+
@error_message = format_error(@error_message) unless @error_message.nil?
|
56
89
|
# copies the stacktrace for tests that have failed
|
57
|
-
|
58
|
-
|
59
|
-
|
90
|
+
FileUtils.cp(
|
91
|
+
"#{ENV['HOME']}/.chef/local-mode-cache/cache/chef-stacktrace.out",
|
92
|
+
"./#{dir}/#{log_basename}_stacktrace.out"
|
93
|
+
) unless @error_message.nil?
|
94
|
+
@error_message.nil?
|
60
95
|
end
|
61
96
|
failure_message do
|
62
97
|
@error_message
|
63
98
|
end
|
64
|
-
end
|
99
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chef-provisioning-opennebula
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew J. Brown
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2016-02-
|
15
|
+
date: 2016-02-29 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: chef
|
@@ -123,23 +123,33 @@ files:
|
|
123
123
|
- lib/chef/resource/one_user.rb
|
124
124
|
- lib/chef/resource/one_vnet.rb
|
125
125
|
- lib/chef/resource/one_vnet_lease.rb
|
126
|
+
- spec/config_sample.rb
|
126
127
|
- spec/integration/test_all_integration_spec.rb
|
127
|
-
- spec/recipes/attach_back_one_vm_spec.rb
|
128
|
-
- spec/recipes/attach_back_two_vm_spec.rb
|
129
|
-
- spec/recipes/attach_one_image_spec.rb
|
130
|
-
- spec/recipes/converge_back_one_vm_spec.rb
|
131
|
-
- spec/recipes/converge_back_two_vm_spec.rb
|
132
|
-
- spec/recipes/converge_bootstrap_vm_spec.rb
|
133
|
-
- spec/recipes/create_back_one_vm_spec.rb
|
134
|
-
- spec/recipes/create_back_two_vm_spec.rb
|
135
|
-
- spec/recipes/create_bootstrap_vm_spec.rb
|
136
|
-
- spec/recipes/create_one_image_spec.rb
|
137
|
-
- spec/recipes/
|
138
|
-
- spec/recipes/
|
128
|
+
- spec/recipes/OneDriver/attach_back_one_vm_spec.rb
|
129
|
+
- spec/recipes/OneDriver/attach_back_two_vm_spec.rb
|
130
|
+
- spec/recipes/OneDriver/attach_one_image_spec.rb
|
131
|
+
- spec/recipes/OneDriver/converge_back_one_vm_spec.rb
|
132
|
+
- spec/recipes/OneDriver/converge_back_two_vm_spec.rb
|
133
|
+
- spec/recipes/OneDriver/converge_bootstrap_vm_spec.rb
|
134
|
+
- spec/recipes/OneDriver/create_back_one_vm_spec.rb
|
135
|
+
- spec/recipes/OneDriver/create_back_two_vm_spec.rb
|
136
|
+
- spec/recipes/OneDriver/create_bootstrap_vm_spec.rb
|
137
|
+
- spec/recipes/OneDriver/create_one_image_spec.rb
|
138
|
+
- spec/recipes/OneDriver/create_one_template_int_spec.rb
|
139
|
+
- spec/recipes/OneDriver/create_one_template_spec.rb
|
140
|
+
- spec/recipes/OneDriver/delete/OpenNebula-back-1-vm.rb
|
141
|
+
- spec/recipes/OneDriver/delete/OpenNebula-back-2-vm.rb
|
142
|
+
- spec/recipes/OneDriver/delete/OpenNebula-bootstrap-img.rb
|
143
|
+
- spec/recipes/OneDriver/delete/OpenNebula-bootstrap-vm.rb
|
144
|
+
- spec/recipes/OneDriver/delete/OpenNebula-snap-1-img.rb
|
145
|
+
- spec/recipes/OneDriver/delete/OpenNebula-snap-2-img.rb
|
146
|
+
- spec/recipes/OneDriver/delete/OpenNebula-test-tpl-ints.rb
|
147
|
+
- spec/recipes/OneDriver/delete/OpenNebula-test-tpl.rb
|
148
|
+
- spec/recipes/OneDriver/delete/OpenNebula-tpl-1-vm.rb
|
149
|
+
- spec/recipes/OneDriver/instantiate_one_template_spec.rb
|
150
|
+
- spec/recipes/OneDriver/snapshot_one_image_spec.rb
|
151
|
+
- spec/recipes/OneDriver/snapshot_two_image_spec.rb
|
139
152
|
- spec/recipes/driver_options_spec.rb
|
140
|
-
- spec/recipes/instantiate_one_template_spec.rb
|
141
|
-
- spec/recipes/snapshot_one_image_spec.rb
|
142
|
-
- spec/recipes/snapshot_two_image_spec.rb
|
143
153
|
- spec/spec_helper.rb
|
144
154
|
- spec/support/opennebula_support.rb
|
145
155
|
homepage: https://github.com/blackberry/chef-provisioning-opennebula
|
@@ -1,20 +0,0 @@
|
|
1
|
-
# Copyright 2015, BlackBerry, Inc.
|
2
|
-
#
|
3
|
-
#Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
#you may not use this file except in compliance with the License.
|
5
|
-
#You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
#Unless required by applicable law or agreed to in writing, software
|
10
|
-
#distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
#See the License for the specific language governing permissions and
|
13
|
-
#limitations under the License.
|
14
|
-
|
15
|
-
require 'chef/provisioning/opennebula_driver'
|
16
|
-
|
17
|
-
one_image "OpenNebula-snap-1-img" do
|
18
|
-
machine_id 'OpenNebula-back-1-vm'
|
19
|
-
action :attach
|
20
|
-
end
|