createResource
Creates a new resource. For a proxy resource, proxyHostName and proxyPort arguments refer to the proxying CloudBees CD/RO agent. hostName and port refer to the proxy target.
Arguments
Argument Name | Type | Description |
---|---|---|
resourceName | String | Name for the resource; must be unique among all resources. (Required) |
artifactCacheDirectory | String | Artifact cache directory for this resource. |
block | Boolean | True to block on the agent ping before returning. |
description | String | Comment text describing this object that is not interpreted at all by CloudBees CD/RO. |
hostName | String | The domain name or IP address of the server machine corresponding to this resource. |
hostType | String | The type of the host. |
pools | String | [Deprecated] A list of arbitrary names separated by spaces, indicating the pools with which this resource is associated. |
port | Integer | Port number to use when connecting to the agent for this resource; defaults to server default. |
proxyCustomization | String | Proxy specific customization data; defaults to none. |
proxyHostName | String | The domain name or IP address of the proxy agent machine corresponding to this resource. |
proxyPort | Integer | Port number to use when connecting to the proxy agent for this resource; defaults to server default. |
proxyProtocol | String | The protocol to use when proxying to this resource; defaults to none. |
repositoryNames | String | A newline delimited list of repositories to retrieve artifacts from. |
resourceDisabled | Boolean | True means this resource will not be allocated to job steps, regardless of its step limit. |
resourcePools | String | A list of arbitrary names separated by comma, indicating the pools with which this resource is associated. |
shell | String | Name of the shell program that will execute the command and postprocessor for the step. |
stepLimit | Integer | The maximum number of steps that may execute simultaneously using this resource. |
trusted | Boolean | True means the agent can speak to all other trusted agents in its zone. An untrusted agent can only speak to gateway agents. |
useSSL | Boolean | True means SSL is used for communication. |
workspaceName | String | The name of the workspace. |
zoneName | String | Name for the zone; must be unique among all zones. |
deleteResource
getAvailableResourcesForEnvironment
getResource
getResourcesInEnvironmentTemplateTier
Retrieve all resources in an environment template tier.
Arguments
Argument Name | Type | Description |
---|---|---|
projectName | String | The name for the project that must be unique among all projects. (Required) |
environmentTemplateName | String | The name of the environment template. (Required) |
environmentTemplateTierName | String | Name for the environment template tier; must be unique among all tiers for the environment template. (Required) |
Usage
import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*
ElectricFlow ef = new ElectricFlow()
def result = ef.getResourcesInEnvironmentTemplateTier(
projectName: 'test-projectName',
environmentTemplateName: 'test-environmentTemplateName',
environmentTemplateTierName: 'test-environmentTemplateTierName')
getResourcesInEnvironmentTier
Return the list of resources in an environment tier.
Arguments
Argument Name | Type | Description |
---|---|---|
projectName | String | The name for the project that must be unique among all projects. (Required) |
environmentName | String | The name of the environment. (Required) |
environmentTierName | String | Name for the environment tier; must be unique among all tiers for the environment. (Required) |
Usage
import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*
ElectricFlow ef = new ElectricFlow()
def result = ef.getResourcesInEnvironmentTier(
projectName: 'test-projectName',
environmentName: 'test-environmentName',
environmentTierName: 'test-environmentTierName')
getResourcesInPool
modifyResource
Modifies an existing resource. For a proxy resource, proxyHostName and proxyPort arguments refer to the proxying CloudBees CD/RO agent. hostName and port refer to the proxy target.
Arguments
Argument Name | Type | Description |
---|---|---|
resourceName | String | Name for the resource; must be unique among all resources. (Required) |
artifactCacheDirectory | String | Artifact cache directory for this resource. |
block | Boolean | True to block on the agent ping before returning. |
description | String | Comment text describing this object that is not interpreted at all by CloudBees CD/RO. |
hostName | String | The domain name or IP address of the server machine corresponding to this resource. |
hostType | String | The type of the host. |
newName | String | New name for an existing object that is being renamed. |
pools | String | [Deprecated] A list of arbitrary names separated by spaces, indicating the pools with which this resource is associated. |
port | Integer | Port number to use when connecting to the agent for this resource; defaults to server default. |
proxyCustomization | String | Proxy specific customization data; defaults to none. |
proxyHostName | String | The domain name or IP address of the proxy agent machine corresponding to this resource. |
proxyPort | Integer | Port number to use when connecting to the proxy agent for this resource; defaults to server default. |
proxyProtocol | String | The protocol to use when proxying to this resource; defaults to none. |
repositoryNames | String | A newline delimited list of repositories to retrieve artifacts from. |
resourceDisabled | Boolean | True means this resource will not be allocated to job steps, regardless of its step limit. |
resourcePools | String | A list of arbitrary names separated by comma, indicating the pools with which this resource is associated. |
shell | String | Name of the shell program that will execute the command and postprocessor for the step. |
stepLimit | Integer | The maximum number of steps that may execute simultaneously using this resource. |
trusted | Boolean | True means the agent can speak to all other trusted agents in its zone. An untrusted agent can only speak to gateway agents. |
useSSL | Boolean | True means SSL is used for communication. |
workspaceName | String | The name of the workspace. |
zoneName | String | Name for the zone; must be unique among all zones. |
pingAllResources
pingResource
removeResourceFromEnvironmentTemplateTier
Removes the given resource from the given environment template tier.
Arguments
Argument Name | Type | Description |
---|---|---|
projectName | String | The name for the project that must be unique among all projects. (Required) |
environmentTemplateName | String | The name of the environment template. (Required) |
environmentTemplateTierName | String | Name for the environment template tier; must be unique among all tiers for the environment template. (Required) |
resourceName | String | Name for the resource; must be unique among all resources. (Required) |
Usage
import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*
ElectricFlow ef = new ElectricFlow()
def result = ef.removeResourceFromEnvironmentTemplateTier(
projectName: 'test-projectName',
environmentTemplateName: 'test-environmentTemplateName',
environmentTemplateTierName: 'test-environmentTemplateTierName',
resourceName: 'test-resourceName')
removeResourceFromEnvironmentTier
Removes the given resource from the given environment tier.
Arguments
Argument Name | Type | Description |
---|---|---|
projectName | String | The name for the project that must be unique among all projects. (Required) |
environmentName | String | The name of the environment. (Required) |
environmentTierName | String | Name for the environment tier; must be unique among all tiers for the environment. (Required) |
resourceName | String | Name for the resource; must be unique among all resources. (Required) |
Usage
import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*
ElectricFlow ef = new ElectricFlow()
def result = ef.removeResourceFromEnvironmentTier(
projectName: 'test-projectName',
environmentName: 'test-environmentName',
environmentTierName: 'test-environmentTierName',
resourceName: 'test-resourceName')
removeResourcesFromEnvironmentTier
Removes the given resources from the given environment tier.
Arguments
Argument Name | Type | Description |
---|---|---|
projectName | String | The name for the project that must be unique among all projects. (Required) |
environmentName | String | The name of the environment. (Required) |
environmentTierName | String | Name for the environment tier; must be unique among all tiers for the environment. (Required) |
resourceNames | String array | List of resources to remove from the environment tier. |
Usage
import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*
ElectricFlow ef = new ElectricFlow()
def result = ef.removeResourcesFromEnvironmentTier(
projectName: 'test-projectName',
environmentName: 'test-environmentName',
environmentTierName: 'test-environmentTierName', )