持续交付
参数 | 类型 | 是否必选 | 示例值 | 描述 |
参数 | 类型 | 是否必选 | 示例值 | 描述 |
Action | String | 是 | CreatePipeline | 接口名称。当前 API 的名称为 CreatePipeline。 |
Version | String | 是 | 2023-05-01 | 接口版本。当前 API 的版本为 2023-05-01。 |
WorkspaceId | String | 是 | 18be9d623fba45a1aca409f5e19c**** | |
Name | String | 是 | Automated Iterative Build Pipeline | 流水线的名称,支持任意字符,长度限制为 2~50 个字符,且在同一个工作区下名称唯一。 |
Description | String | 否 | Automated build and release pipeline for daily iterative versions. | 用于补充说明流水线的相关信息,支持任意字符,长度限制为 0~256 个字符,未传入时默认值为空字符串。 |
Spec | String | 否 | version: 2.0.0\nagentPool: public/prod-v2-public\nstages:\n - stage: exec-cmd\n displayName: Execute Command\n tasks:\n - task: exec-cmd\n displayName: Execute Command\n steps:\n - step: exec-cmd\n displayName: Execute Command\n component: exec@1.0.0\n inputs:\n shell: BASH\n cmd: echo hello\n workspace: {}\n dependsOn: []\n resourcesPolicy: all\n timeout: 2h\n resources:\n limits:\n cpu: 1C\n memory: 2Gi\n | |
Parameters | 否 | - | 用于静态替换流水线配置中 $(parameter.xxx) 占位符的变量集合,最多可配置 100 个变量,未传入时默认值为空列表。 | |
Caches | 否 | - | 流水线缓存配置列表。 |
参数 | 类型 | 是否必选 | 示例值 | 描述 |
参数 | 类型 | 是否必选 | 示例值 | 描述 |
Key | String | 否 | build_branch | 流水线变量的名称。 |
Value | String | 否 | release-v2.3.1 | 流水线变量的具体取值。 |
Secret | Boolean | 否 | false | 变量是否开启隐私设置。
|
Dynamic | Boolean | 否 | false | 变量是否开启动态设置。
|
OptionValues | Array of String | 否 | ["release-v2.3.1","develop-v2.4.0","hotfix-v2.3.2"] | 当变量配置为单选选项类型时,用于指定该变量可选择的所有可选值列表,可选值为字符串类型且长度小于 16KB。 |
Description | String | 否 | Specifies the build branch for the iterative version. | 变量的备注。 |
参数 | 类型 | 是否必选 | 示例值 | 描述 |
参数 | 类型 | 是否必选 | 示例值 | 描述 |
Key | String | 是 | cache-test | 缓存目录的名称。 |
Path | String | 是 | $(CP_WORKSPACE)/.m2 | 缓存的路径,需要设置为$(CP_WORKSPACE)的子目录。 |
Description | String | 否 | Stores the initial version. | 缓存目录的备注。 |
参数 | 类型 | 示例值 | 描述 |
参数 | 类型 | 示例值 | 描述 |
Id | String | 18be9d623fba45a1aca409f5e19c**** | 流水线 ID。 |