createPluginConfiguration

Back to index

Summary

Creates a new plugin configuration.
projectName
Stringrequired
The name for the project that must be unique among all projects.
pluginConfigurationName
Stringrequired
Unique name of the plugin configuration within the project.
credentialReferenceParameter
Arrayoptional
List of credential parameters with references to existing credentials as parameter values. If the parameter value is a property reference then the credential would be resolved at runtime.
credential
Arrayoptional
Credentials to be used by the plugin config.
description
Stringoptional
Comment text describing this object that is not interpreted at all by CloudBees CD/RO.
field
Arrayoptional
Fields for plugin configuration.
pluginKey
Stringoptional
The plugin key.
pluginProjectName
Stringoptional
The name for the plugin's project.

Usage

Perl

$cmdr->createPluginConfiguration( "test-projectName", # projectName "test-pluginConfigurationName" # pluginConfigurationName # optionals );

ectool

ectool createPluginConfiguration \ "test-projectName" `# projectName` \ "test-pluginConfigurationName" `# pluginConfigurationName` \ # optionals

Examples

ectool

Example 1

ectool createPluginConfiguration projectA test-git-00 --pluginKey EC-Git --field authType=token library=jgit --credential token_credential=new_git_cred --description "test git configuration 00"

Response:

<response requestId="1" nodeId="192.168.250.178"> <pluginConfiguration> <pluginConfigurationId>620815fc-df1b-11eb-8657-a4c3f0873bac</pluginConfigurationId> <pluginConfigurationName>test-git-00</pluginConfigurationName> <createTime>2021-07-07T12:03:46.629Z</createTime> <description>test git configuration 00</description> <lastModifiedBy>admin</lastModifiedBy> <modifyTime>2021-07-07T12:03:46.629Z</modifyTime> <owner>admin</owner> <pluginKey>EC-Git</pluginKey> <projectName>projectA</projectName> <propertySheetId>6208b23e-df1b-11eb-8657-a4c3f0873bac</propertySheetId> <tracked>1</tracked> <credentialMappings> <parameterDetail> <parameterName>token_credential</parameterName> <parameterType>runtime</parameterType> <parameterValue>/projects/projectA/credentials/test-git-00-token_credential-20210707150346</parameterValue> </parameterDetail> </credentialMappings> <fields> <parameterDetail> <parameterName>authType</parameterName> <parameterValue>token</parameterValue> </parameterDetail> <parameterDetail> <parameterName>library</parameterName> <parameterValue>jgit</parameterValue> </parameterDetail> </fields> </pluginConfiguration> </response>

Example 2

ectool createPluginConfiguration projectA test-git-01 --pluginKey EC-Git --field authType=password library=jgit --credentialReferenceParameter credential=/projects/projectA/credentials/git_creds --description "test git configuration 01"

Response:

<response requestId="1" nodeId="192.168.250.178"> <pluginConfiguration> <pluginConfigurationId>c66369dc-df25-11eb-b9d0-a4c3f0873bac</pluginConfigurationId> <pluginConfigurationName>test-git-01</pluginConfigurationName> <createTime>2021-07-07T13:18:10.002Z</createTime> <description>test git configuration 01</description> <lastModifiedBy>admin</lastModifiedBy> <modifyTime>2021-07-07T13:18:10.002Z</modifyTime> <owner>admin</owner> <pluginKey>EC-Git</pluginKey> <projectName>projectA</projectName> <propertySheetId>c663b7fe-df25-11eb-b9d0-a4c3f0873bac</propertySheetId> <tracked>1</tracked> <credentialMappings> <parameterDetail> <parameterName>credential</parameterName> <parameterType>reference</parameterType> <parameterValue>/projects/projectA/credentials/git_creds</parameterValue> </parameterDetail> </credentialMappings> <fields> <parameterDetail> <parameterName>authType</parameterName> <parameterValue>password</parameterValue> </parameterDetail> <parameterDetail> <parameterName>library</parameterName> <parameterValue>jgit</parameterValue> </parameterDetail> </fields> </pluginConfiguration> </response>