chef-provisioning-opennebula 0.4.8 → 0.4.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +2 -3
- data/lib/chef/provisioning/opennebula_driver/driver.rb +7 -1
- data/lib/chef/provisioning/opennebula_driver/version.rb +1 -1
- data/spec/config_sample.rb +19 -18
- data/spec/integration/one_driver_spec.rb +84 -0
- data/spec/integration/one_flow_spec.rb +340 -0
- data/spec/recipes/OneDriver/{instantiate_one_template_vnet.rb → allocate_one_vm.rb} +6 -4
- data/spec/recipes/OneDriver/attach_one_image.rb +2 -2
- data/spec/recipes/OneDriver/converge_one_vm.rb +17 -0
- data/spec/recipes/OneDriver/create_one_image.rb +1 -1
- data/spec/recipes/OneDriver/create_one_template.rb +18 -0
- data/spec/recipes/OneDriver/create_one_vnet.rb +2 -2
- data/spec/recipes/OneDriver/{delete/OpenNebula-test-vm.rb → delete_one_img.rb} +1 -1
- data/spec/recipes/OneDriver/{delete/OpenNebula-test-img.rb → delete_one_snap-img.rb} +1 -1
- data/spec/recipes/{OneFlowService/delete/test_role_action.rb → OneDriver/delete_one_template.rb} +1 -1
- data/spec/recipes/OneDriver/{delete/OpenNebula-test-vm-vnet.rb → delete_one_vm.rb} +1 -1
- data/spec/recipes/OneDriver/{delete/OpenNebula-test-vnet.rb → delete_one_vnet.rb} +1 -1
- data/spec/recipes/OneDriver/ready_one_vm.rb +17 -0
- data/spec/recipes/OneDriver/snapshot_one_image.rb +3 -3
- data/spec/recipes/OneDriver/update_one_template.rb +20 -0
- data/spec/recipes/{OneFlowTemplate/create_branch_from_one_id.rb → OneFlow/branch_json_template_by_id.rb} +6 -6
- data/spec/recipes/OneFlow/branch_json_template_by_name.rb +42 -0
- data/spec/recipes/{OneFlowTemplate/chmod_simple_from_hash.rb → OneFlow/chmod_file_template.rb} +1 -1
- data/spec/recipes/{OneFlowService/chmod_simple_by_name_2.rb → OneFlow/chmod_json_service_by_id.rb} +2 -2
- data/spec/recipes/{OneFlowService/instance_simple_by_name.rb → OneFlow/chmod_json_service_by_name.rb} +2 -2
- data/spec/recipes/{OneDriver/delete/OpenNebula-test-snap-img.rb → OneFlow/chmod_json_template.rb} +2 -2
- data/spec/recipes/OneFlow/create_file_template.rb +18 -0
- data/spec/recipes/{OneFlowTemplate/create_tpl_opts_from_hash.rb → OneFlow/create_file_template_with_opts.rb} +8 -11
- data/spec/recipes/OneFlow/create_http_template.rb +17 -0
- data/spec/recipes/{OneFlowService/instance_simple_by_id.rb → OneFlow/create_json_service_by_id.rb} +4 -2
- data/spec/recipes/{OneFlowService/chmod_simple_by_name.rb → OneFlow/create_json_service_by_name.rb} +2 -2
- data/spec/recipes/{OneFlowService/instance_tpl_opts.rb → OneFlow/create_json_service_with_opts.rb} +8 -6
- data/spec/recipes/{OneFlowTemplate/create_simple_from_hash.rb → OneFlow/create_json_template.rb} +4 -3
- data/spec/recipes/{OneFlowTemplate/create_tpl_opts_from_file.rb → OneFlow/create_json_template_with_opts.rb} +15 -7
- data/spec/recipes/{OneFlowService/instance_role_action.rb → OneFlow/create_role_action_service.rb} +8 -8
- data/spec/recipes/OneFlow/create_role_action_template.rb +89 -0
- data/spec/recipes/OneFlow/delete_branched_template_by_id.rb +17 -0
- data/spec/recipes/OneFlow/delete_branched_template_by_name.rb +17 -0
- data/spec/recipes/{OneDriver/delete/OpenNebula-test-tpl-strings.rb → OneFlow/delete_file_template.rb} +1 -1
- data/spec/recipes/OneFlow/delete_file_template_with_opts.rb +17 -0
- data/spec/recipes/{OneDriver/delete/OpenNebula-test-tpl-ints.rb → OneFlow/delete_http_template.rb} +1 -1
- data/spec/recipes/{OneDriver/delete/OpenNebula-test-tpl-mix.rb → OneFlow/delete_json_service_by_id.rb} +1 -1
- data/spec/recipes/OneFlow/delete_json_service_by_name.rb +17 -0
- data/spec/recipes/OneFlow/delete_json_service_with_opts.rb +17 -0
- data/spec/recipes/OneFlow/delete_json_template.rb +17 -0
- data/spec/recipes/OneFlow/delete_json_template_with_opts.rb +17 -0
- data/spec/recipes/OneFlow/delete_role_action_service.rb +17 -0
- data/spec/recipes/OneFlow/delete_role_action_template.rb +17 -0
- data/spec/recipes/{OneFlowService/action/boot.rb → OneFlow/service_action_boot.rb} +4 -3
- data/spec/recipes/OneFlow/service_action_delete.rb +18 -0
- data/spec/recipes/{OneFlowService/action/delete_recreate.rb → OneFlow/service_action_delete_recreate.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/hold.rb → OneFlow/service_action_hold.rb} +4 -3
- data/spec/recipes/{OneFlowService/action/poweroff.rb → OneFlow/service_action_poweroff.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/poweroff_hard.rb → OneFlow/service_action_poweroff_hard.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/reboot.rb → OneFlow/service_action_reboot.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/reboot_hard.rb → OneFlow/service_action_reboot_hard.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/release.rb → OneFlow/service_action_release.rb} +4 -3
- data/spec/recipes/OneFlow/service_action_resume_poweroff.rb +18 -0
- data/spec/recipes/OneFlow/service_action_resume_poweroff_hard.rb +18 -0
- data/spec/recipes/{OneFlowService/action/resume.rb → OneFlow/service_action_resume_stop.rb} +2 -2
- data/spec/recipes/OneFlow/service_action_resume_suspend.rb +18 -0
- data/spec/recipes/OneFlow/service_action_resume_undeploy.rb +18 -0
- data/spec/recipes/OneFlow/service_action_resume_undeploy_hard.rb +18 -0
- data/spec/recipes/{OneFlowService/action/scale.rb → OneFlow/service_action_scale.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/shutdown.rb → OneFlow/service_action_shutdown.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/shutdown_hard.rb → OneFlow/service_action_shutdown_hard.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/snapshot_create.rb → OneFlow/service_action_snapshot_create.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/stop.rb → OneFlow/service_action_stop.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/suspend.rb → OneFlow/service_action_suspend.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/undeploy.rb → OneFlow/service_action_undeploy.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/undeploy_hard.rb → OneFlow/service_action_undeploy_hard.rb} +2 -2
- data/spec/recipes/{OneFlowService/action/shutdown_service.rb → OneFlow/shutdown_role_action_service.rb} +1 -1
- data/spec/recipes/{OneFlowTemplate/update_simple_from_hash.rb → OneFlow/update_json_template.rb} +17 -14
- data/spec/recipes/common.rb +0 -2
- data/spec/spec_helper.rb +97 -42
- metadata +86 -89
- data/spec/integration/test_all_integration_spec.rb +0 -21
- data/spec/integration/test_one_driver.rb +0 -177
- data/spec/integration/test_one_flow.rb +0 -546
- data/spec/recipes/OneDriver/allocate_change_profile.rb +0 -23
- data/spec/recipes/OneDriver/create_one_template_ints.rb +0 -38
- data/spec/recipes/OneDriver/create_one_template_mix.rb +0 -51
- data/spec/recipes/OneDriver/create_one_template_strings.rb +0 -34
- data/spec/recipes/OneDriver/instantiate_one_template.rb +0 -21
- data/spec/recipes/OneFlowService/action/delete.rb +0 -18
- data/spec/recipes/OneFlowService/chmod_tpl_opts.rb +0 -31
- data/spec/recipes/OneFlowService/delete/test_instance_template_options.rb +0 -17
- data/spec/recipes/OneFlowService/delete/test_simple_instance.rb +0 -17
- data/spec/recipes/OneFlowService/delete/test_simple_instance_by_id.rb +0 -17
- data/spec/recipes/OneFlowTemplate/chmod_update_simple_from_file.rb +0 -19
- data/spec/recipes/OneFlowTemplate/create_branch_from_one_name.rb +0 -20
- data/spec/recipes/OneFlowTemplate/create_role_action_instance.rb +0 -99
- data/spec/recipes/OneFlowTemplate/create_simple_from_file.rb +0 -18
- data/spec/recipes/OneFlowTemplate/create_simple_from_web.rb +0 -17
- data/spec/recipes/OneFlowTemplate/create_simple_instance_tpl.rb +0 -22
- data/spec/recipes/OneFlowTemplate/delete/branch_from_one_id.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/branch_from_one_name.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/role_action_instance.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/simple_from_file.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/simple_from_hash.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/simple_from_web.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/simple_instance_tpl.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/tpl_opts_from_file.rb +0 -17
- data/spec/recipes/OneFlowTemplate/delete/tpl_opts_from_hash.rb +0 -17
- data/spec/support/opennebula_support.rb +0 -129
@@ -12,17 +12,19 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
|
15
|
+
username = one_auth.split(':').first
|
16
|
+
machine 'RSpec-test-vm' do
|
16
17
|
machine_options MACHINE_OPTIONS.merge(
|
17
18
|
:bootstrap_options => {
|
18
|
-
:template_name => '
|
19
|
+
:template_name => 'RSpec-test-template',
|
19
20
|
:template_options => {
|
20
21
|
'NIC' => {
|
21
|
-
'NETWORK' => '
|
22
|
+
'NETWORK' => 'RSpec-test-vnet',
|
22
23
|
'NETWORK_UNAME' => username
|
23
24
|
}
|
24
25
|
},
|
25
|
-
:mode => '
|
26
|
+
:mode => '600'
|
26
27
|
}
|
27
28
|
)
|
29
|
+
action :allocate
|
28
30
|
end
|
@@ -12,7 +12,7 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_image '
|
16
|
-
machine_id '
|
15
|
+
one_image 'RSpec-test-img' do
|
16
|
+
machine_id 'RSpec-test-vm'
|
17
17
|
action :attach
|
18
18
|
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
machine 'RSpec-test-vm' do
|
16
|
+
action :converge
|
17
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
one_template 'RSpec-test-template' do
|
16
|
+
template VM_TEMPLATE
|
17
|
+
action :create_if_missing
|
18
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
machine 'RSpec-test-vm' do
|
16
|
+
action :ready
|
17
|
+
end
|
@@ -12,8 +12,8 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_image '
|
16
|
-
machine_id '
|
17
|
-
disk_id '
|
15
|
+
one_image 'RSpec-test-snap-img' do
|
16
|
+
machine_id 'RSpec-test-vm'
|
17
|
+
disk_id 'RSpec-test-img'
|
18
18
|
action :snapshot
|
19
19
|
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
VM_TEMPLATE.merge!({ 'CPU' => '0.1' })
|
16
|
+
|
17
|
+
one_template 'RSpec-test-template' do
|
18
|
+
template VM_TEMPLATE
|
19
|
+
action :create
|
20
|
+
end
|
@@ -12,20 +12,20 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
id = Chef::Provisioning::OpenNebulaDriver::FlowLib.new(ONE_FLOW_URL, one_auth).get_unique_template_id('
|
15
|
+
id = Chef::Provisioning::OpenNebulaDriver::FlowLib.new(ONE_FLOW_URL, one_auth).get_unique_template_id('RSpec-flow-json-template')
|
16
16
|
|
17
|
-
one_flow_template '
|
18
|
-
name 'gary2'
|
17
|
+
one_flow_template 'RSpec-branch-json-template-by-id' do
|
19
18
|
template id
|
20
|
-
template_options :name => '
|
19
|
+
template_options :name => 'RSpec-branch-json-template-by-id',
|
21
20
|
:description => 'my description is very descriptive',
|
22
21
|
:roles => [
|
23
22
|
{
|
24
|
-
:name => '
|
23
|
+
:name => 'RSpecRetest',
|
25
24
|
:delete_role => true
|
26
25
|
},
|
27
26
|
{
|
28
|
-
:name => '
|
27
|
+
:name => 'RSpecTest',
|
28
|
+
:cooldown => 1,
|
29
29
|
:scheduled_policies => [
|
30
30
|
{
|
31
31
|
:type => "CHANGE",
|
@@ -0,0 +1,42 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
one_flow_template 'RSpec-branch-json-template-by-name' do
|
16
|
+
template 'RSpec-flow-json-template'
|
17
|
+
template_options :name => 'RSpec-branch-json-template-by-name',
|
18
|
+
:description => 'my description is very descriptive',
|
19
|
+
:roles => [
|
20
|
+
{
|
21
|
+
:name => 'RSpecRetest',
|
22
|
+
:delete_role => true
|
23
|
+
},
|
24
|
+
{
|
25
|
+
:name => 'RSpecTest',
|
26
|
+
:scheduled_policies => [
|
27
|
+
{
|
28
|
+
:type => "CHANGE",
|
29
|
+
:cooldown => 2,
|
30
|
+
:adjust => 1,
|
31
|
+
:start_time => "0 3 1-10 * *"
|
32
|
+
},
|
33
|
+
{
|
34
|
+
:type => "CARDINALITY",
|
35
|
+
:cooldown => 2,
|
36
|
+
:recurrence => "0 4 1-10 * *",
|
37
|
+
:adjust => 1
|
38
|
+
}
|
39
|
+
]
|
40
|
+
}
|
41
|
+
]
|
42
|
+
end
|
data/spec/recipes/{OneFlowService/chmod_simple_by_name_2.rb → OneFlow/chmod_json_service_by_id.rb}
RENAMED
@@ -12,7 +12,7 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_service '
|
16
|
-
mode '
|
15
|
+
one_flow_service 'RSpec-json-service-by-id' do
|
16
|
+
mode '640'
|
17
17
|
action :instantiate
|
18
18
|
end
|
@@ -12,7 +12,7 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_service '
|
16
|
-
template 'test_simple_instance_tpl'
|
15
|
+
one_flow_service 'RSpec-json-service-by-name' do
|
17
16
|
mode '640'
|
17
|
+
action :instantiate
|
18
18
|
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
one_flow_template 'RSpec-flow-file-template' do
|
16
|
+
name 'RSpec-flow-file-template'
|
17
|
+
template 'file:///tmp/RSpec-flow-file-template.json'
|
18
|
+
end
|
@@ -12,24 +12,21 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_template '
|
16
|
-
template
|
17
|
-
:roles => [
|
18
|
-
{
|
19
|
-
:name => 'gary_ubuntu',
|
20
|
-
:vm_template => 'OpenNebula-test-tpl-strings'
|
21
|
-
}
|
22
|
-
]
|
15
|
+
one_flow_template 'RSpec-flow-file-template-with-opts' do
|
16
|
+
template 'file:///tmp/RSpec-flow-file-template-with-opts.json'
|
23
17
|
template_options :deployment => 'none',
|
18
|
+
:ready_status_gate => false,
|
24
19
|
:roles => [
|
25
20
|
{
|
26
|
-
:name => '
|
21
|
+
:name => 'RSpecTest',
|
27
22
|
:delete_role => true
|
28
23
|
},
|
29
24
|
{
|
30
|
-
:name => '
|
31
|
-
:vm_template => '
|
25
|
+
:name => 'RSpecRetest',
|
26
|
+
:vm_template => 'RSpec-test-template',
|
27
|
+
:cooldown => 2
|
32
28
|
}
|
33
29
|
]
|
30
|
+
mode '640'
|
34
31
|
action :create
|
35
32
|
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# Copyright 2016, BlackBerry Limited
|
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
|
+
one_flow_template 'RSpec-flow-http-template' do
|
16
|
+
template JSON_TEMPLATE_URL
|
17
|
+
end
|
data/spec/recipes/{OneFlowService/instance_simple_by_id.rb → OneFlow/create_json_service_by_id.rb}
RENAMED
@@ -12,9 +12,11 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
id = Chef::Provisioning::OpenNebulaDriver::FlowLib.new(ONE_FLOW_URL, one_auth)
|
15
|
+
id = Chef::Provisioning::OpenNebulaDriver::FlowLib.new(ONE_FLOW_URL, one_auth)
|
16
|
+
.get_unique_template_id('RSpec-branch-json-template-by-id')
|
16
17
|
|
17
|
-
one_flow_service '
|
18
|
+
one_flow_service 'RSpec-json-service-by-id' do
|
18
19
|
template id
|
20
|
+
mode '600'
|
19
21
|
action :instantiate
|
20
22
|
end
|
data/spec/recipes/{OneFlowService/chmod_simple_by_name.rb → OneFlow/create_json_service_by_name.rb}
RENAMED
@@ -12,8 +12,8 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_service '
|
16
|
-
template '
|
15
|
+
one_flow_service 'RSpec-json-service-by-name' do
|
16
|
+
template 'RSpec-branch-json-template-by-name'
|
17
17
|
mode '600'
|
18
18
|
action :instantiate
|
19
19
|
end
|
data/spec/recipes/{OneFlowService/instance_tpl_opts.rb → OneFlow/create_json_service_with_opts.rb}
RENAMED
@@ -12,18 +12,20 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_service '
|
16
|
-
template '
|
17
|
-
template_options :name => '
|
15
|
+
one_flow_service 'RSpec-json-service-with-opts' do
|
16
|
+
template 'RSpec-flow-json-template-with-opts'
|
17
|
+
template_options :name => 'RSpec-json-service-with-opts',
|
18
18
|
:deployment => 'none',
|
19
|
+
:ready_status_gate => false,
|
19
20
|
:roles => [
|
20
21
|
{
|
21
|
-
:name => '
|
22
|
+
:name => 'RSpecTest',
|
22
23
|
:delete_role => true
|
23
24
|
},
|
24
25
|
{
|
25
|
-
:name => '
|
26
|
-
:vm_template => '
|
26
|
+
:name => 'RSpecRetest',
|
27
|
+
:vm_template => 'RSpec-test-template',
|
28
|
+
:cooldown => 2
|
27
29
|
}
|
28
30
|
]
|
29
31
|
action :instantiate
|
data/spec/recipes/{OneFlowTemplate/create_simple_from_hash.rb → OneFlow/create_json_template.rb}
RENAMED
@@ -12,11 +12,12 @@
|
|
12
12
|
# See the License for the specific language governing permissions and
|
13
13
|
# limitations under the License.
|
14
14
|
|
15
|
-
one_flow_template '
|
15
|
+
one_flow_template 'RSpec-flow-json-template' do
|
16
16
|
template :roles => [
|
17
17
|
{
|
18
|
-
:name => '
|
19
|
-
:vm_template => '
|
18
|
+
:name => 'RSpecTest',
|
19
|
+
:vm_template => 'RSpec-test-template',
|
20
|
+
:cooldown => 2
|
20
21
|
}
|
21
22
|
]
|
22
23
|
end
|