A VmCluster
is used to represent a set of virtual machines. It is mainly used to deploy services/apps to the specified clusters and in some cases, it can be used to run certain maintenance activities on the clusters as a whole.
YAML Schema
VmCluster
- name: vmIntegrationResource type: VmCluster configuration: sshKey: <sshKey integration name> targets: - <IP address> - <IP address> - <IP address>
Tags
name
An alphanumeric string (underscores are permitted) that identifies the resource.
type
Must be VmCluster
for this resource type.
configuration
Specifies all configuration selections for the resource.
Tag | Description | Required/Optional |
---|---|---|
| The name of an SSH Key Integration | Required |
| Declares a collection of IP addresses of Virtual Machines in the clusters | Required |
Environment Variables
Whenever VmCluster
is used in a step, a set of environment variables is automatically made available that you can use in your step.
Environment Variable | Description |
---|---|
res_<resource_name>_name | Name of the resource |
res_<resource_name>_sshkey | Name of the SSH Key integration |
res_<resource_name>_targets | The collection of IP addresses |
Example
The Pipelines DSL for this example is available in this repository in the JFrog GitHub account.
resources: - name: vmCluster_1 type: VmCluster configuration: sshKey: SR_SSHKEYS targets: - 1.2.3.4 pipelines: - name: pipelines_1 steps: - name: VM_0001 type: PowerShell configuration: inputResources: - name: vmCluster_1 execution: onExecute: - write-output "executing step..."