Name: kitchen-vra
Owner: Chef Partners
Description: Test Kitchen driver for VMware vRealize Automation
Created: 2015-08-05 18:34:50.0
Updated: 2018-03-06 14:13:16.0
Pushed: 2018-03-01 22:08:29.0
Homepage: null
Size: 62
Language: Ruby
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
A driver to allow Test Kitchen to consume vRealize Automation (vRA) resources to perform testing.
Add this line to your application's Gemfile:
'kitchen-vra'
And then execute:
$ bundle
Or install it yourself as:
$ gem install kitchen-vra
Or even better, install it via ChefDK:
$ chef gem install kitchen-vra
After installing the gem as described above, edit your .kitchen.yml file to set the driver to 'vra' and supply your login credentials:
er:
me: vra
ername: myuser@corp.local
ssword: mypassword
nant: mytenant
se_url: https://vra.corp.local
rify_ssl: true
If you want username and password to be prompted, remove usename and password in your .kitchen.yml as shown below:
er:
me: vra
nant: mytenant
se_url: https://vra.corp.local
rify_ssl: true
If you don't want to explicitly specify username and password in the kitchen.yml, you have an option to set it in the environment variable as
$ export VRA_USER_NAME='myuser@corp.local'
$ export VRA_USER_PASSWORD='mypassword'
Then configure your platforms. Either a catalog_id or a catalog_name is required for each platform. If both catalog_id and catalog_name are mentioned in .kitchen.yml then catalog_name would be used to derive the catalog_id and this catalog_id would override the catalog_id being passed in .kitchen.yml. In the below example as can be seen we are using catalog_id for centos6 driver while catalog_name for the centos7 driver just to demonstrate that we can use either of the two.
forms:
name: centos6
driver:
catalog_id: e9db1084-d1c6-4c1f-8e3c-eb8f3dc574f9
name: centos7
driver:
catalog_name: my_catalog_name
Other options that you can set include:
wait_until_ready
method with a growing sleep in between each attempt. Defaults to 1. Set to 0 to disable any retrying of the wait_until_ready
method.driver
section.false
. Set to true
if vRA doesn't manage vm ip addresses. This will cause kitchen to attempt to connect via hostname.nil
. Set to your domain suffix, for example 'mydomain.com'. This only takes effect when use_dns
== true and is appended to the hostname returned by vRA.These settings can be set globally under the top-level driver
section, or they can be set on each platform, which allows you to set globals and then override them. For example, this configuration would set the CPU count to 1 except on the “large” platform:
er:
me: vra
us: 1
forms:
name: small
driver:
catalog_name: my_catalog_name_small
catalog_id: 8a189191-fea6-43eb-981e-ee0fa40f8f57
extra_parameters:
provider-mycustompropname:
type: string
value: smallvalue
provider-Vrm.DataCenter.Location:
type: string
value: Non-Prod
name: large
driver:
catalog_name: my_catalog_name_large
catalog_id: 1d7c6122-18fa-4ed6-bd13-8a33b6c6ed50
cpus: 2
subtenant_name: my_subtenant_name
extra_parameters:
provider-mycustompropname:
type: string
value: largevalue
provider-Vrm.DataCenter.Location:
type: string
value: Prod
Author:: Chef Partner Engineering (partnereng@chef.io)
Copyright:: Copyright (c) 2015-2017 Chef Software, Inc.
License:: Apache License, Version 2.0
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
We'd love to hear from you if this doesn't work in your vRA environment. Please log a GitHub issue, or even better, submit a Pull Request with a fix!
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)