Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update docs to support VRA8 and modify .gitignore file #1838

Merged
merged 3 commits into from
Jan 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,6 @@ _cache
.tddium*
docs/public
.idea/
docs/.hugo_build.lock


1 change: 1 addition & 0 deletions docs/content/docs/drivers/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Chef Workstation includes:
* [kitchen-openstack](https://github.com/test-kitchen/kitchen-openstack)
* [kitchen-vagrant](https://github.com/test-kitchen/kitchen-vagrant)
* [kitchen-vcenter](https://github.com/chef/kitchen-vcenter)
* [kitchen-vra](https://github.com/chef/kitchen-vra)

Community Drivers:

Expand Down
82 changes: 82 additions & 0 deletions docs/content/docs/drivers/vra.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
---
title: VMware vRealize Automation
menu:
docs:
parent: drivers
weight: 15
---

kitchen-vra is a Test Kitchen driver for vRealize Automation that runs against the VMware vRealize Automation [V8.x] API.

## Usage

After installing the gem as described above, edit your .kitchen.yml file to set the driver to 'vra' and supply your login credentials:

```yaml
driver:
name: vra
username: myuser@corp.local
password: mypassword
tenant: mytenant
base_url: https://vra.corp.local
verify_ssl: true
```

If you want username and password to be prompted, remove usename and password in your .kitchen.yml as shown below:

```yaml
driver:
name: vra
tenant: mytenant
base_url: https://vra.corp.local
verify_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'

Example **kitchen.yml**:

```yaml
driver:
name: vra
username: myuser@corp.local
password: <%= ENV['VRA_USER_PASSWORD'] %>
tenant: bedford.progress.com
project_id: xxxxx-xxxxxxxx
base_url: https://lxmarpvra8-01.bedford.progress.com
verify_ssl: false
image_mapping: VRA-nc-lnx-ce8.4-Docker
flavor_mapping: Small
version: 1

provisioner:
name: chef_zero

platforms:
- name: chef-progress
driver:
catalog_id: 97aac381-327d-3b5c-ad93-e18fc855045e
extra_parameters:
hardware-config:
type: string
value: Small

suites:
- name: default
run_list:
- recipe[my_cookbook::default]
```

* **image_mapping**: specifies the OS image for a machine and the flavor_mapping specifies the CPU count and RAM of the machine.
* **flavor_mapping**: flavor mapping groups a set of target deployment sizings for a specific cloud account/region.

Other options that you can set include:

* **request_timeout**: amount of time, in seconds, to wait for a vRA request to complete. Default is 600 seconds.
* **server_ready_retries**: Number of times to retry the "waiting for server to be ready" check. In some cases, this will error out immediately due to DNS propagation issues, etc. Setting this to a number greater than 0 will retry the `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.
* **private_key_path**: path to the SSH private key to use when logging in. Defaults to '~/.ssh/id_rsa' or '~/.ssh/id_dsa', preferring the RSA key. Only applies to instances where SSH transport is used; i.e., does not apply to Windows hosts with the WinRM transport configured.
* **use_dns**: Defaults to `false`. Set to `true` if vRA doesn't manage vm ip addresses. This will cause kitchen to attempt to connect via hostname.
* **dns_suffix**: Defaults to `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.
* **extra_parameters**: a hash of other data to set on a catalog request, most notably custom properties. Allows updates to existing properties on the blueprint as well as the addition of new properties. Each key in the hash is the property name, and the value is a another hash containing the value data type and the value itself. It is possible to use a `~` to add nested parameters.