beaker 3.21.1 → 3.22.0

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
- NTU2YTkyMzA2NzA5NmZhMzNjNDY1ODc1YjhiZTQ5NzdhZDM1OTlmNA==
4
+ MDNlYWQ5NWZjNDVjNzA3OGU2NjZiYjJjYzZmMGE2ZTQ1M2E0NTAyOQ==
5
5
  data.tar.gz: !binary |-
6
- OTRiN2MxOGUxNGQ2N2UwMDhjYjQyNTBkMzY3YjA5Mjc0Mzk0MGUxMA==
6
+ OGE5ZGYxYzg4MzNjMWEzZWExMjcwY2E3OWVhYjEyODM4ZmQ2ZWI2ZA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- OTRkYmJlYTViOTgyNTY1Mjk0NjQ1ODM0NDJhZjkyNDc2ZGM2M2RlNzg2NDJj
10
- MGE3MDIxYzFkMjgzYjZjMzc4NzU0M2Y0MjdjOTAyNmFkYmIyMWU0Yjg4MmY3
11
- OGNmOTUyMTZhY2MwMGI4OWFlZTAxZTdkOTU1MDZjOGEyMzJkODc=
9
+ MjRiNTAyNmNlNmU2OTA3OTJhMWYxZDFkZWJkMjVkODRmMWNmMTYzNzljMGEx
10
+ NTRkNDdiMmI5YWJkNmEyNmJhNTBkMzliNTgwMDc3N2VmZDczY2UyYzZmZWI5
11
+ OTUxMmQ3ZGNjZjE3NTlkZTk5NTJiNjIwNDY4NmVlMmE4MTE5OWQ=
12
12
  data.tar.gz: !binary |-
13
- NGJmNDJiOTAwNzFjYmU3Y2VhYmZiMGJiMmMxODVmNDA1Yzg3ZTY5YTg2MWM2
14
- YjIxMzhkYzliNjc2MTA5M2VmMjVjZmQ0ODhkNTU3MGEzMjcxODZjODhjZWI4
15
- YWRlYjE4NjgyNmUxNjkwNDlkNTRjMDlhNWE3ZTUxNGM1ODY2YjE=
13
+ ODQwYThmMTc3NmQwYTQ1ODhkMGNlMDlmYjkxMWFhN2YxYzZhYTlmNTE5OWMw
14
+ YzAyMTg0NGU2NDE0NDNiZjA3ODJhMWQ3MzE5NzhjNTM2N2Y4ZWY3ZjE0NzAy
15
+ MmJlODdhMWMwYTIxODY3Mjg5ZTk3MGVlYjExM2U5ZmU0MDc1ZWY=
@@ -40,7 +40,7 @@ test_name "dsl::helpers::host_helpers #archive_file_from" do
40
40
  expected_path = File.join(tmpdir, default)
41
41
 
42
42
  tgz = Zlib::GzipReader.new(File.open(tar_path, 'rb'))
43
- Archive::Tar::Minitar.unpack(tgz, expected_path)
43
+ Minitar.unpack(tgz, expected_path)
44
44
  assert_equal('number of the beast', File.read(expected_path + '/' + filepath).strip)
45
45
  end
46
46
  end
@@ -32,7 +32,7 @@ Gem::Specification.new do |s|
32
32
 
33
33
  # Run time dependencies
34
34
  s.add_runtime_dependency 'minitest', '~> 5.4'
35
- s.add_runtime_dependency 'minitar', '~> 0.5.4'
35
+ s.add_runtime_dependency 'minitar', '~> 0.6'
36
36
 
37
37
  s.add_runtime_dependency 'hocon', '~> 1.0'
38
38
  s.add_runtime_dependency 'net-ssh', '~> 4.0'
@@ -50,13 +50,19 @@ Gem::Specification.new do |s|
50
50
  s.add_runtime_dependency 'beaker-hostgenerator'
51
51
  s.add_runtime_dependency 'beaker-puppet', '~> 0.0'
52
52
 
53
+ # A minor setback for a major comeback (BKR-841)
54
+ #
55
+ # Beaker uses nokogiri but it was not declared as direct dependency
56
+ # before as one of the hypervisor gems included it
57
+ s.add_runtime_dependency 'nokogiri', '~> 1.8.0'
58
+
53
59
  # Optional provisioner specific support
54
- s.add_runtime_dependency 'docker-api'
55
- s.add_runtime_dependency 'fog', '~> 1.38'
60
+ s.add_runtime_dependency 'beaker-docker', '~> 0.1'
56
61
  s.add_runtime_dependency 'beaker-aws', '~> 0.1'
57
62
  s.add_runtime_dependency 'beaker-vmpooler', '~> 0.1'
58
63
  s.add_runtime_dependency 'beaker-google', '~> 0.1'
59
64
  s.add_runtime_dependency 'beaker-vagrant', '~> 0.1'
60
65
  s.add_runtime_dependency 'beaker-vmware', '~> 0.1'
66
+ s.add_runtime_dependency 'beaker-openstack', '~> 0.1'
61
67
 
62
68
  end
@@ -41,13 +41,15 @@ In order to offset this, we've made a listing of gems and community-supported fo
41
41
 
42
42
  Hypervisor gems made by puppet (pre-included in beaker 3.x):
43
43
 
44
- | Hypervisor | Fork |
45
- | :----------------------: | :---------------------------------------------------------: |
46
- | Vmpooler | [beaker-vmpooler](https://github.com/puppetlabs/beaker-vmpooler) |
47
- | AWS | [beaker-aws](https://github.com/puppetlabs/beaker-aws) |
48
- | Google Compute | [beaker-google](https://github.com/puppetlabs/beaker-google) |
49
- | Vagrant | [beaker-vagrant](https://github.com/puppetlabs/beaker-vagrant) |
50
- | VMware/Vsphere | [beaker-vmware](https://github.com/puppetlabs/beaker-vmware) |
44
+ | Hypervisor | Fork |
45
+ | :----------------------: | :---------------------------------------------------------: |
46
+ | Vmpooler | [beaker-vmpooler](https://github.com/puppetlabs/beaker-vmpooler) |
47
+ | AWS | [beaker-aws](https://github.com/puppetlabs/beaker-aws) |
48
+ | Vagrant | [beaker-vagrant](https://github.com/puppetlabs/beaker-vagrant) |
49
+ | VMware/Vsphere | [beaker-vmware](https://github.com/puppetlabs/beaker-vmware) |
50
+ | Docker | [beaker-docker](https://github.com/puppetlabs/beaker-docker) |
51
+ | Openstack | [beaker-openstack](https://github.com/puppetlabs/beaker-openstack) |
52
+ | Google Compute | [beaker-google](https://github.com/puppetlabs/beaker-google) |
51
53
 
52
54
  Hypervisor gems and beaker forks made by community:
53
55
 
@@ -260,7 +260,7 @@ module Beaker
260
260
  #
261
261
  # @return [Result] Returns the result of the #scp_from operation.
262
262
  def archive_file_from(host, from_path, opts = {}, archive_root = 'archive/sut-files', archive_name = 'sut-files.tgz')
263
- require 'archive/tar/minitar'
263
+ require 'minitar'
264
264
  filedir = File.dirname(from_path)
265
265
  targetdir = File.join(archive_root, host.hostname, filedir)
266
266
  # full path to check for existance later
@@ -277,7 +277,7 @@ module Beaker
277
277
  # @visibility private
278
278
  def create_tarball(path, archive_name)
279
279
  tgz = Zlib::GzipWriter.new(File.open(archive_name, 'wb'))
280
- Archive::Tar::Minitar.pack(path, tgz)
280
+ Minitar.pack(path, tgz)
281
281
  end
282
282
  private :create_tarball
283
283
 
@@ -185,7 +185,7 @@ module PSWindows::Exec
185
185
  keys = [key_str]
186
186
  keys << key_str.upcase if key_str.upcase != key_str
187
187
  keys.each do |env_key|
188
- env_array << "#{env_key}=\"#{val}\""
188
+ env_array << "#{env_key}=#{val}"
189
189
  end
190
190
  end
191
191
  env_array
@@ -22,14 +22,6 @@ module Beaker
22
22
  @logger.notify("Beaker::Hypervisor, found some #{type} boxes to create")
23
23
 
24
24
  hyper_class = case type
25
- when /^aix$/
26
- Beaker::Aixer
27
- when /^solaris$/
28
- Beaker::Solaris
29
- when /^docker$/
30
- Beaker::Docker
31
- when /^openstack$/
32
- Beaker::OpenStack
33
25
  when /^noop$/
34
26
  Beaker::Noop
35
27
  when /^(default)|(none)$/
@@ -120,10 +112,4 @@ module Beaker
120
112
  end
121
113
  end
122
114
 
123
- [
124
- 'docker',
125
- 'openstack',
126
- 'noop'
127
- ].each do |lib|
128
- require "beaker/hypervisor/#{lib}"
129
- end
115
+ require "beaker/hypervisor/noop"
@@ -1,5 +1,5 @@
1
1
  module Beaker
2
2
  module Version
3
- STRING = '3.21.1'
3
+ STRING = '3.22.0'
4
4
  end
5
5
  end
@@ -59,12 +59,12 @@ module Beaker
59
59
 
60
60
  it 'takes an env hash with var_name/value pairs' do
61
61
  expect( instance.environment_string( {:HOME => '/', :http_proxy => 'http://foo'} ) ).
62
- to be == 'set "HOME="/"" && set "http_proxy="http://foo"" && set "HTTP_PROXY="http://foo"" && '
62
+ to be == 'set "HOME=/" && set "http_proxy=http://foo" && set "HTTP_PROXY=http://foo" && '
63
63
  end
64
64
 
65
65
  it 'takes an env hash with var_name/value[Array] pairs' do
66
66
  expect( instance.environment_string( {:LD_PATH => ['/', '/tmp']}) ).
67
- to be == "set \"LD_PATH=\"/:/tmp\"\" && "
67
+ to be == "set \"LD_PATH=/:/tmp\" && "
68
68
  end
69
69
  end
70
70
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: beaker
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.21.1
4
+ version: 3.22.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Puppet
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-07-26 00:00:00.000000000 Z
11
+ date: 2017-08-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -128,14 +128,14 @@ dependencies:
128
128
  requirements:
129
129
  - - ~>
130
130
  - !ruby/object:Gem::Version
131
- version: 0.5.4
131
+ version: '0.6'
132
132
  type: :runtime
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - ~>
137
137
  - !ruby/object:Gem::Version
138
- version: 0.5.4
138
+ version: '0.6'
139
139
  - !ruby/object:Gem::Dependency
140
140
  name: hocon
141
141
  requirement: !ruby/object:Gem::Requirement
@@ -305,33 +305,33 @@ dependencies:
305
305
  - !ruby/object:Gem::Version
306
306
  version: '0.0'
307
307
  - !ruby/object:Gem::Dependency
308
- name: docker-api
308
+ name: nokogiri
309
309
  requirement: !ruby/object:Gem::Requirement
310
310
  requirements:
311
- - - ! '>='
311
+ - - ~>
312
312
  - !ruby/object:Gem::Version
313
- version: '0'
313
+ version: 1.8.0
314
314
  type: :runtime
315
315
  prerelease: false
316
316
  version_requirements: !ruby/object:Gem::Requirement
317
317
  requirements:
318
- - - ! '>='
318
+ - - ~>
319
319
  - !ruby/object:Gem::Version
320
- version: '0'
320
+ version: 1.8.0
321
321
  - !ruby/object:Gem::Dependency
322
- name: fog
322
+ name: beaker-docker
323
323
  requirement: !ruby/object:Gem::Requirement
324
324
  requirements:
325
325
  - - ~>
326
326
  - !ruby/object:Gem::Version
327
- version: '1.38'
327
+ version: '0.1'
328
328
  type: :runtime
329
329
  prerelease: false
330
330
  version_requirements: !ruby/object:Gem::Requirement
331
331
  requirements:
332
332
  - - ~>
333
333
  - !ruby/object:Gem::Version
334
- version: '1.38'
334
+ version: '0.1'
335
335
  - !ruby/object:Gem::Dependency
336
336
  name: beaker-aws
337
337
  requirement: !ruby/object:Gem::Requirement
@@ -402,6 +402,20 @@ dependencies:
402
402
  - - ~>
403
403
  - !ruby/object:Gem::Version
404
404
  version: '0.1'
405
+ - !ruby/object:Gem::Dependency
406
+ name: beaker-openstack
407
+ requirement: !ruby/object:Gem::Requirement
408
+ requirements:
409
+ - - ~>
410
+ - !ruby/object:Gem::Version
411
+ version: '0.1'
412
+ type: :runtime
413
+ prerelease: false
414
+ version_requirements: !ruby/object:Gem::Requirement
415
+ requirements:
416
+ - - ~>
417
+ - !ruby/object:Gem::Version
418
+ version: '0.1'
405
419
  description: Puppet's accceptance testing harness
406
420
  email:
407
421
  - delivery@puppet.com
@@ -555,8 +569,6 @@ files:
555
569
  - docs/how_to/hosts/cisco.md
556
570
  - docs/how_to/hosts/eos.md
557
571
  - docs/how_to/hypervisors/README.md
558
- - docs/how_to/hypervisors/docker.md
559
- - docs/how_to/hypervisors/openstack.md
560
572
  - docs/how_to/hypervisors/solaris.md
561
573
  - docs/how_to/install_puppet.md
562
574
  - docs/how_to/platform_specific_tag_confines.md
@@ -639,9 +651,7 @@ files:
639
651
  - lib/beaker/host/windows/user.rb
640
652
  - lib/beaker/host_prebuilt_steps.rb
641
653
  - lib/beaker/hypervisor.rb
642
- - lib/beaker/hypervisor/docker.rb
643
654
  - lib/beaker/hypervisor/noop.rb
644
- - lib/beaker/hypervisor/openstack.rb
645
655
  - lib/beaker/junit.xsl
646
656
  - lib/beaker/logger.rb
647
657
  - lib/beaker/logger_junit.rb
@@ -711,10 +721,8 @@ files:
711
721
  - spec/beaker/host/windows_spec.rb
712
722
  - spec/beaker/host_prebuilt_steps_spec.rb
713
723
  - spec/beaker/host_spec.rb
714
- - spec/beaker/hypervisor/docker_spec.rb
715
724
  - spec/beaker/hypervisor/hypervisor_spec.rb
716
725
  - spec/beaker/hypervisor/hypervisor_spec.rb.orig
717
- - spec/beaker/hypervisor/openstack_spec.rb
718
726
  - spec/beaker/logger_junit_spec.rb
719
727
  - spec/beaker/logger_spec.rb
720
728
  - spec/beaker/network_manager_spec.rb
@@ -1,148 +0,0 @@
1
- This option allows for testing against Docker containers.
2
-
3
-
4
- ### Why?
5
-
6
- Using docker as a hypervisor significantly speeds up the provisioning process, as you don't have to spin up an entire VM to run the tests, which has significant overhead.
7
-
8
- ### How?
9
-
10
- So first of all, install Docker using the instructions [here](https://docs.docker.com/installation/#installation).
11
-
12
- In the real world, it's generally seen as [bad practice to have sshd running in a Docker container](http://blog.docker.com/2014/06/why-you-dont-need-to-run-sshd-in-docker/). However, for the purpose of a disposable test instance, we're not going to worry about that!
13
-
14
- ### Basic docker hosts file ###
15
- The base image to use for the container is named by the image key.
16
-
17
- HOSTS:
18
- ubuntu-12-10:
19
- platform: ubuntu-12.10-x64
20
- image: ubuntu:12.10
21
- hypervisor: docker
22
- CONFIG:
23
- type: foss
24
-
25
- ### Docker hosts file, with image modification ###
26
- You can specify extra commands to be executed in order to modify the image with the `docker_image_commands` key.
27
-
28
- HOSTS:
29
- ubuntu-12-10:
30
- platform: ubuntu-12.10-x64
31
- image: ubuntu:12.10
32
- hypervisor: docker
33
- docker_image_commands:
34
- - 'apt-get install -y myapp'
35
- - 'myapp --setup'
36
- CONFIG:
37
- type: foss
38
-
39
- ### Docker hosts files, with modified start commands ###
40
- By default the docker container just runs an sshd which is adequate for 'puppet apply' style testing. You can specify a different command to start with the `docker_cmd` key. This gives you scope to run something with more service supervision baked into it, but it is is important that this command starts an sshd listening on port 22 so that beaker can drive the container.
41
-
42
- HOSTS:
43
- ubuntu-12-10:
44
- platform: ubuntu-12.10-x64
45
- image: ubuntu:12.10
46
- hypervisor: docker
47
- docker_cmd: '["/sbin/init"]'
48
- CONFIG:
49
- type: foss
50
-
51
- ### Preserve Docker Image ###
52
- Unless the image configuration changes you might want to keep the Docker image for multiple spec runs. Use `docker_preserve_image` option for a host.
53
-
54
- HOSTS:
55
- ubuntu-12-10:
56
- platform: ubuntu-12.10-x64
57
- image: ubuntu:12.10
58
- hypervisor: docker
59
- docker_preserve_image: true
60
- CONFIG:
61
- type: foss
62
-
63
- ### Reuse Docker Image ###
64
- In case you want to rerun the puppet again on the docker container, you can pass BEAKER_provision=no on the command line to set the env. Add this line in you default.ml file
65
-
66
- ```
67
- HOSTS:
68
- centos6-64:
69
- roles:
70
- - agent
71
- platform: el-6-x86_64
72
- image: centos:6.6
73
- hypervisor: docker
74
- CONFIG:
75
- type: foss
76
- log_level: verbose
77
- ssh:
78
- password: root
79
- auth_methods: ["password"]
80
- ```
81
-
82
- ### Mounting volumes into your docker container ###
83
- You can mount folders into a docker container:
84
-
85
- HOSTS:
86
- ubuntu-12-10:
87
- platform: ubuntu-12.10-x64
88
- image: ubuntu:12.10
89
- hypervisor: docker
90
- mount_folders:
91
- name1:
92
- host_path: host_path1
93
- container_path: container_path1
94
- name2:
95
- host_path: host_path2
96
- container_path: container_path2
97
- opts: rw
98
- CONFIG:
99
- type: foss
100
-
101
- ### Example Output
102
-
103
- For this example made a new docker nodeset file in the [puppetlabs-inifile](https://github.com/puppetlabs/puppetlabs-inifile) repo and ran the ini_setting_spec.rb spec:
104
-
105
- ```bash
106
- $ bundle exec rspec spec/acceptance/ini_setting_spec.rb
107
- Hypervisor for debian-7 is docker
108
- Beaker::Hypervisor, found some docker boxes to create
109
- Provisioning docker
110
- provisioning debian-7
111
- Creating image
112
- Dockerfile is FROM debian:7.4
113
- RUN apt-get update
114
- RUN apt-get install -y openssh-server openssh-client curl ntpdate lsb-release
115
- RUN mkdir -p /var/run/sshd
116
- RUN echo root:root | chpasswd
117
- RUN apt-get install -yq lsb-release wget net-tools ruby rubygems ruby1.8-dev libaugeas-dev libaugeas-ruby ntpdate locales-all
118
- RUN REALLY_GEM_UPDATE_SYSTEM=1 gem update --system --no-ri --no-rdoc
119
- EXPOSE 22
120
- CMD ["/sbin/init"]
121
- ```
122
-
123
- This step may take a while, as Docker will have to download the image. The subsequent runs will be a lot faster (as long as `docker_preserve_image: true` has been enabled).
124
-
125
- For example, running this took 5 minutes to download and setup the `debian:7.4` image, but runs instantly the second time.
126
-
127
- You should then see something like:
128
-
129
- ```
130
- Creating container from image 3a86e5aba94d
131
- post
132
- /v1.15/containers/create
133
- {}
134
- {"Image":"3a86e5aba94d","Hostname":"debian-7"}
135
- Starting container b8b31702b34b4aedd137c8a6a72fe730560bb00533e68764ba6263405f9244e4
136
- post
137
- /v1.15/containers/b8b31702b34b4aedd137c8a6a72fe730560bb00533e68764ba6263405f9244e4/start
138
- {}
139
- {"PublishAllPorts":true,"Privileged":true}
140
- Using docker server at 192.168.59.103
141
- get
142
- /v1.15/containers/b8b31702b34b4aedd137c8a6a72fe730560bb00533e68764ba6263405f9244e4/json
143
- {}
144
-
145
- node available as ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no root@192.168.59.103 -p 49155
146
- ```
147
-
148
- The tests should then run as normal from there.
@@ -1,166 +0,0 @@
1
- # Openstack
2
-
3
- OpenStack is a free and open-source software platform for cloud computing. [Their Site](http://www.openstack.org/).
4
-
5
- Considered **EXPERIMENTAL**, may break without notice.
6
-
7
- # Getting Started
8
-
9
- ### Requirements
10
-
11
- Get openstack Access & Security credentials:
12
-
13
- - "openstack_api_key"
14
- - "openstack_auth_url"
15
- - "openstack_username"
16
- - "openstack_tenant"
17
- - "openstack_network"
18
- - "openstack_keyname"
19
-
20
- If you are using [OpenStack Dashboard "Horizon"] (https://wiki.openstack.org/wiki/Horizon)
21
- you can find these keys in next places:
22
-
23
- 1. login to "Horizon dashboard" -> "project" -> "Compute" -> "Access & Security" -> tab "API Access" -> "Download OpenStack RC File":
24
- * "openstack_auth_url" == OS_AUTH_URL + "/tokens"
25
- * "openstack_username" == OS_USERNAME
26
- * "openstack_tenant" == OS_TENANT_NAME
27
- 2. "openstack_network": in "project" -> "Networks"
28
- 3. "openstack_keyname": in "project" -> "Compute" -> "Access & Security" -> tab "Key Pairs"
29
- 4. "openstack_api_key": Your user Password
30
-
31
- ### Setup a Openstack Hosts File
32
-
33
- An Openstack hosts file looks like a typical hosts file,
34
- except that there are a number of required properties that need to be added to every host
35
- in order for the Openstack hypervisor to provision hosts properly.
36
-
37
- **Basic Openstack hosts file**
38
-
39
- HOSTS:
40
- centos-6-master:
41
- roles:
42
- - master
43
- - agent
44
- - database
45
- - dashboard
46
- platform: el-6-x86_64
47
- hypervisor: openstack
48
- image: centos-6-x86_64-nocm
49
- flavor: m1.large
50
-
51
- CONFIG:
52
- nfs_server: none
53
- consoleport: 443
54
- openstack_api_key: Pas$w0rd
55
- openstack_username: user
56
- openstack_auth_url: http://10.10.10.10:5000/v2.0/tokens
57
- openstack_tenant: testing
58
- openstack_network : testing
59
- openstack_keyname : nopass
60
-
61
- The `image` - image name.
62
-
63
- The `flavor` - templates for VMs, defining sizes for RAM, disk, number of cores, and so on.
64
-
65
-
66
- # Openstack-Specific Hosts File Settings
67
-
68
- ### user-data
69
-
70
- "user data" - a blob of data that the user can specify when they launch an instance.
71
- The instance can access this data through the metadata service or config drive with one of the next requests:
72
-
73
- - curl http://169.254.169.254/2009-04-04/user-data
74
- - curl http://169.254.169.254/openstack/2012-08-10/user_data
75
-
76
-
77
- Examples of `user_data` you can find here: http://cloudinit.readthedocs.io/en/latest/topics/examples.html
78
-
79
- Also if you plan use `user-data` make sure that 'cloud-init' package installed in your VM `image` and 'cloud-init' service is running.
80
-
81
- **Example Openstack hosts file with user_data**
82
-
83
- HOSTS:
84
- centos-6-master:
85
- roles:
86
- - master
87
- - agent
88
- - database
89
- - dashboard
90
- platform: el-6-x86_64
91
- image: centos-6-x86_64-nocm
92
- flavor: m1.large
93
- hypervisor: openstack
94
- user_data: |
95
- #cloud-config
96
- bootcmd:
97
- - echo 123 > /tmp/test.txt
98
- CONFIG:
99
- nfs_server: none
100
- consoleport: 443
101
- openstack_api_key: P1as$w0rd
102
- openstack_username: user
103
- openstack_auth_url: http://10.10.10.10:5000/v2.0/tokens
104
- openstack_tenant: testing
105
- openstack_network : testing
106
- openstack_keyname : nopass
107
-
108
- ### Security groups
109
-
110
- A security group is a set of rules for incoming and outgoing traffic to
111
- an instance. You can associate a host with one or many security groups
112
- in the `CONFIG` section of your hosts file:
113
-
114
- security_group: ['my_sg', 'default']
115
-
116
- This is an optional config parameter.
117
-
118
- ### Floating IP Pool
119
-
120
- The name of the floating IP pool that a VM can grab IPs from. This is useful
121
- if your organization doesn't have a public pool of floating IPs, or give each
122
- user their own pool. It's used in allocating new IPs. It's an options
123
- parameter in the CONFIG section of the host file:
124
-
125
- floating_ip_pool: 'my_pool_name'
126
-
127
- ### Volumes
128
-
129
- Attaching volumes to a VM is supported via the Cinder service. All versions are transparently
130
- supported to cater for differences in the APIs. To create and attach volumes simply add hash
131
- called 'volumes' to a host in the HOSTS section. Each key is the name given to the volume upon
132
- resource creation. The value is a hash with a single integer parameter 'size' which defines the
133
- volume size in MB.
134
-
135
- **Example OpenStack hosts file with volumes**
136
-
137
- HOSTS:
138
- ceph:
139
- roles:
140
- - master
141
- platform: ubuntu-16.04-amd64
142
- hypervisor: openstack
143
- flavor: m1.large
144
- image: xenial-server-cloudimg-amd64-scsi
145
- user: ubuntu
146
- volumes:
147
- osd0:
148
- size: 10000
149
- osd1:
150
- size: 10000
151
- osd2:
152
- size: 10000
153
- journal:
154
- size: 1000
155
-
156
-
157
- In the event you're using an OpenStack instance that does not deploy the volume service you can disable that functionality to prevent beaker runs from failing. Either using an ENV variable or setting the following value in the `CONFIG` section of your hosts file(valid values are `true` or `false`):
158
-
159
- ```
160
- openstack_volume_support: false
161
- ```
162
-
163
- You can also configure this setting via an environment variable:
164
-
165
- ```
166
- export OS_VOLUME_SUPPORT=false