你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Microsoft.ContainerRegistry registries/taskRuns 2019-06-01-preview
Bicep 资源定义
可以使用面向以下操作部署 registries/taskRuns 资源类型:
- 资源组 - 请参阅 资源组部署命令
有关每个 API 版本中更改的属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ContainerRegistry/registries/taskRuns 资源,请将以下 Bicep 添加到模板。
resource symbolicname 'Microsoft.ContainerRegistry/registries/taskRuns@2019-06-01-preview' = {
name: 'string'
location: 'string'
parent: resourceSymbolicName
identity: {
principalId: 'string'
tenantId: 'string'
type: 'string'
userAssignedIdentities: {}
}
properties: {
forceUpdateTag: 'string'
runRequest: {
agentPoolName: 'string'
isArchiveEnabled: bool
logTemplate: 'string'
type: 'string'
// For remaining properties, see RunRequest objects
}
}
}
RunRequest 对象
设置 type 属性以指定对象的类型。
对于 DockerBuildRequest,请使用:
type: 'DockerBuildRequest'
agentConfiguration: {
cpu: int
}
arguments: [
{
isSecret: bool
name: 'string'
value: 'string'
}
]
credentials: {
customRegistries: {}
sourceRegistry: {
loginMode: 'string'
}
}
dockerFilePath: 'string'
imageNames: [
'string'
]
isPushEnabled: bool
noCache: bool
platform: {
architecture: 'string'
os: 'string'
variant: 'string'
}
sourceLocation: 'string'
target: 'string'
timeout: int
对于 EncodedTaskRunRequest,请使用:
type: 'EncodedTaskRunRequest'
agentConfiguration: {
cpu: int
}
credentials: {
customRegistries: {}
sourceRegistry: {
loginMode: 'string'
}
}
encodedTaskContent: 'string'
encodedValuesContent: 'string'
platform: {
architecture: 'string'
os: 'string'
variant: 'string'
}
sourceLocation: 'string'
timeout: int
values: [
{
isSecret: bool
name: 'string'
value: 'string'
}
]
对于 FileTaskRunRequest,请使用:
type: 'FileTaskRunRequest'
agentConfiguration: {
cpu: int
}
credentials: {
customRegistries: {}
sourceRegistry: {
loginMode: 'string'
}
}
platform: {
architecture: 'string'
os: 'string'
variant: 'string'
}
sourceLocation: 'string'
taskFilePath: 'string'
timeout: int
values: [
{
isSecret: bool
name: 'string'
value: 'string'
}
]
valuesFilePath: 'string'
对于 TaskRunRequest,请使用:
type: 'TaskRunRequest'
overrideTaskStepProperties: {
arguments: [
{
isSecret: bool
name: 'string'
value: 'string'
}
]
contextPath: 'string'
file: 'string'
target: 'string'
updateTriggerToken: 'string'
values: [
{
isSecret: bool
name: 'string'
value: 'string'
}
]
}
taskId: 'string'
属性值
registries/taskRuns
名称 | 说明 | 值 |
---|---|---|
name | 资源名称 了解如何在 Bicep 中为子资源设置名称和类型。 |
字符串 (必需) |
location | 资源的位置 | string |
父级 (parent) | 在 Bicep 中,可以为子资源指定父资源。 仅当子资源在父资源外部声明时,才需要添加此属性。 有关详细信息,请参阅 父资源之外的子资源。 |
类型为资源的符号名称: 注册表 |
标识 | 资源的标识。 | IdentityProperties |
properties | 与任务运行关联的属性,即运行的请求和结果 | TaskRunProperties |
IdentityProperties
名称 | 说明 | 值 |
---|---|---|
principalId | 资源标识的主体 ID。 | string |
tenantId | 资源的租户 ID。 | string |
type | 标识类型。 | “None” “SystemAssigned” “SystemAssigned,UserAssigned” “UserAssigned” |
userAssignedIdentities | 与资源关联的用户标识列表。 用户标识 字典键引用将采用以下格式的 ARM 资源 ID: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/ providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'。 |
object |
TaskRunProperties
名称 | 说明 | 值 |
---|---|---|
forceUpdateTag | 应如何强制重新运行(即使运行请求配置未更改) | string |
runRequest | 请求 (运行) 参数 | RunRequest |
RunRequest
名称 | 说明 | 值 |
---|---|---|
agentPoolName | 运行的专用代理池。 | string |
isArchiveEnabled | 指示是否为运行启用存档的值。 | bool |
logTemplate | 描述运行日志项目的存储库和标记信息的模板。 | string |
type | 设置对象类型 | DockerBuildRequest EncodedTaskRunRequest FileTaskRunRequest TaskRunRequest (必需) |
DockerBuildRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “DockerBuildRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
参数 | 在执行运行时要使用的重写参数的集合。 | Argument[] |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
dockerFilePath | 相对于源位置的 Docker 文件路径。 | 字符串 (必需) |
imageNames | 完全限定的映像名称,包括存储库和标记。 | string[] |
isPushEnabled | 此属性的值指示是否应将生成的映像推送到注册表。 | bool |
noCache | 此属性的值指示是否启用图像缓存。 | bool |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
目标 | Docker 生成的目标生成阶段的名称。 | string |
timeout | 运行超时(以秒为单位)。 | int |
AgentProperties
名称 | 说明 | 值 |
---|---|---|
cpu | 运行所需的内核数的 CPU 配置。 | int |
参数
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示参数是否表示机密并想要从生成日志中删除的标志。 | bool |
name | 参数的名称。 | 字符串 (必需) |
值 | 参数的值。 | 字符串 (必需) |
凭据
名称 | 说明 | 值 |
---|---|---|
customRegistries | 介绍用于访问其他自定义注册表的凭据参数。 密钥 字典项的 注册表登录服务器 (myregistry.azurecr.io) 和 项的值将是用于访问注册表的注册表凭据。 |
object |
sourceRegistry | 介绍用于访问源注册表的凭据参数。 | SourceRegistryCredentials |
SourceRegistryCredentials
名称 | 说明 | 值 |
---|---|---|
loginMode | 确定源注册表登录范围的身份验证模式。 源注册表的凭据 将使用给定的范围生成。 这些凭据将用于登录 运行期间的源注册表。 |
'Default' “None” |
PlatformProperties
名称 | 说明 | 值 |
---|---|---|
体系结构 | OS 体系结构。 | '386' “amd64” “arm” “arm64” “x86” |
os | 运行所需的操作系统类型。 | “Linux” “Windows” (必需) |
variant | CPU 的变体。 | “v6” “v7” “v8” |
EncodedTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “EncodedTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
encodedTaskContent | 模板/定义文件内容的 Base64 编码值。 | 字符串 (必需) |
encodedValuesContent | 参数/值文件内容的 Base64 编码值。 | string |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可传递的可重写值的集合。 | SetValue[] |
SetValue
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示值是否表示机密的标志。 | bool |
name | 可重写值的名称。 | 字符串 (必需) |
值 | 可重写的值。 | 字符串 (必需) |
FileTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “FileTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
taskFilePath | 相对于源的模板/定义文件路径。 | 字符串 (必需) |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可传递的可重写值的集合。 | SetValue[] |
valuesFilePath | 相对于源的值/参数文件路径。 | string |
TaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “TaskRunRequest” (必需) |
overrideTaskStepProperties | 运行 Task 时可传递的可重写参数集。 | OverrideTaskStepProperties |
taskId | 必须对其运行进行排队的任务的资源 ID。 | 字符串 (必需) |
OverrideTaskStepProperties
名称 | 说明 | 值 |
---|---|---|
参数 | 获取或设置在以下情况下使用的重写参数的集合 执行生成步骤。 |
Argument[] |
contextPath | 必须对其运行进行排队的源上下文。 | string |
文件 | 运行必须对其排队的文件。 | string |
目标 | docker 生成的目标生成阶段的名称。 | string |
updateTriggerToken | 将附加到基础映像触发器 Webhook 的 Base64 编码更新触发器令牌。 | string |
值 | 运行 Task 时可传递的可重写值的集合。 | SetValue[] |
ARM 模板资源定义
可以使用面向以下操作部署 registries/taskRuns 资源类型:
- 资源组 - 请参阅 资源组部署命令
有关每个 API 版本中已更改属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ContainerRegistry/registries/taskRuns 资源,请将以下 JSON 添加到模板。
{
"type": "Microsoft.ContainerRegistry/registries/taskRuns",
"apiVersion": "2019-06-01-preview",
"name": "string",
"location": "string",
"identity": {
"principalId": "string",
"tenantId": "string",
"type": "string",
"userAssignedIdentities": {}
},
"properties": {
"forceUpdateTag": "string",
"runRequest": {
"agentPoolName": "string",
"isArchiveEnabled": "bool",
"logTemplate": "string",
"type": "string"
// For remaining properties, see RunRequest objects
}
}
}
RunRequest 对象
设置 type 属性以指定对象的类型。
对于 DockerBuildRequest,请使用:
"type": "DockerBuildRequest",
"agentConfiguration": {
"cpu": "int"
},
"arguments": [
{
"isSecret": "bool",
"name": "string",
"value": "string"
}
],
"credentials": {
"customRegistries": {},
"sourceRegistry": {
"loginMode": "string"
}
},
"dockerFilePath": "string",
"imageNames": [ "string" ],
"isPushEnabled": "bool",
"noCache": "bool",
"platform": {
"architecture": "string",
"os": "string",
"variant": "string"
},
"sourceLocation": "string",
"target": "string",
"timeout": "int"
对于 EncodedTaskRunRequest,请使用:
"type": "EncodedTaskRunRequest",
"agentConfiguration": {
"cpu": "int"
},
"credentials": {
"customRegistries": {},
"sourceRegistry": {
"loginMode": "string"
}
},
"encodedTaskContent": "string",
"encodedValuesContent": "string",
"platform": {
"architecture": "string",
"os": "string",
"variant": "string"
},
"sourceLocation": "string",
"timeout": "int",
"values": [
{
"isSecret": "bool",
"name": "string",
"value": "string"
}
]
对于 FileTaskRunRequest,请使用:
"type": "FileTaskRunRequest",
"agentConfiguration": {
"cpu": "int"
},
"credentials": {
"customRegistries": {},
"sourceRegistry": {
"loginMode": "string"
}
},
"platform": {
"architecture": "string",
"os": "string",
"variant": "string"
},
"sourceLocation": "string",
"taskFilePath": "string",
"timeout": "int",
"values": [
{
"isSecret": "bool",
"name": "string",
"value": "string"
}
],
"valuesFilePath": "string"
对于 TaskRunRequest,请使用:
"type": "TaskRunRequest",
"overrideTaskStepProperties": {
"arguments": [
{
"isSecret": "bool",
"name": "string",
"value": "string"
}
],
"contextPath": "string",
"file": "string",
"target": "string",
"updateTriggerToken": "string",
"values": [
{
"isSecret": "bool",
"name": "string",
"value": "string"
}
]
},
"taskId": "string"
属性值
registries/taskRuns
名称 | 说明 | Value |
---|---|---|
type | 资源类型 | 'Microsoft.ContainerRegistry/registries/taskRuns' |
apiVersion | 资源 API 版本 | '2019-06-01-preview' |
name | 资源名称 了解如何在 JSON ARM 模板中设置子资源的名称和类型。 |
字符串 (必需) |
location | 资源的位置 | string |
标识 | 资源的标识。 | IdentityProperties |
properties | 与任务运行关联的属性,即运行的请求和结果 | TaskRunProperties |
IdentityProperties
名称 | 说明 | 值 |
---|---|---|
principalId | 资源标识的主体 ID。 | string |
tenantId | 资源的租户 ID。 | string |
type | 标识类型。 | “None” “SystemAssigned” “SystemAssigned, UserAssigned” “UserAssigned” |
userAssignedIdentities | 与资源关联的用户标识列表。 用户标识 字典键引用将采用以下格式的 ARM 资源 ID: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/ providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'。 |
object |
TaskRunProperties
名称 | 说明 | 值 |
---|---|---|
forceUpdateTag | 如何在运行请求配置未更改的情况下强制重新运行 | string |
runRequest | 运行) 的请求 (参数 | RunRequest |
RunRequest
名称 | 说明 | 值 |
---|---|---|
agentPoolName | 运行的专用代理池。 | string |
isArchiveEnabled | 该值指示是否为运行启用存档。 | bool |
logTemplate | 描述运行日志项目的存储库和标记信息的模板。 | string |
type | 设置对象类型 | DockerBuildRequest EncodedTaskRunRequest FileTaskRunRequest TaskRunRequest (必需) |
DockerBuildRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | 需要“DockerBuildRequest” () |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
参数 | 执行运行时要使用的重写参数的集合。 | Argument[] |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
dockerFilePath | 相对于源位置的 Docker 文件路径。 | 字符串 (必需) |
imageNames | 完全限定的映像名称,包括存储库和标记。 | string[] |
isPushEnabled | 此属性的值指示是否应将生成的映像推送到注册表。 | bool |
noCache | 此属性的值指示是否启用图像缓存。 | bool |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
目标 | docker 生成的目标生成阶段的名称。 | string |
timeout | 运行超时(以秒为单位)。 | int |
AgentProperties
名称 | 说明 | 值 |
---|---|---|
cpu | 运行所需的核心数的 CPU 配置。 | int |
参数
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示参数是否表示机密并想要从生成日志中删除的标志。 | bool |
name | 参数的名称。 | 字符串 (必需) |
值 | 参数的值。 | 字符串 (必需) |
凭据
名称 | 说明 | 值 |
---|---|---|
customRegistries | 介绍用于访问其他自定义注册表的凭据参数。 密钥 字典项的注册表登录服务器 (myregistry.azurecr.io) 和 项的值将是用于访问注册表的注册表凭据。 |
object |
sourceRegistry | 描述用于访问源注册表的凭据参数。 | SourceRegistryCredentials |
SourceRegistryCredentials
名称 | 说明 | 值 |
---|---|---|
loginMode | 确定源注册表登录范围的身份验证模式。 源注册表的凭据 将使用给定的范围生成。 这些凭据将用于登录到 运行期间的源注册表。 |
'Default' “None” |
PlatformProperties
名称 | 说明 | 值 |
---|---|---|
体系结构 | OS 体系结构。 | '386' 'amd64' 'arm' 'arm64' 'x86' |
os | 运行所需的操作系统类型。 | 'Linux' “Windows” (必需) |
variant | CPU 的变体。 | “v6” “v7” “v8” |
EncodedTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “EncodedTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
encodedTaskContent | 模板/定义文件内容的 Base64 编码值。 | 字符串 (必需) |
encodedValuesContent | 参数/值文件内容的 Base64 编码值。 | string |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可传递的可重写值的集合。 | SetValue[] |
SetValue
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示值是否表示机密的标志。 | bool |
name | 可重写值的名称。 | 字符串 (必需) |
值 | 可重写的值。 | 字符串 (必需) |
FileTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “FileTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
taskFilePath | 相对于源的模板/定义文件路径。 | 字符串 (必需) |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可传递的可重写值的集合。 | SetValue[] |
valuesFilePath | 相对于源的值/参数文件路径。 | string |
TaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “TaskRunRequest” (必需) |
overrideTaskStepProperties | 运行 Task 时可传递的可重写参数集。 | OverrideTaskStepProperties |
taskId | 必须对其运行进行排队的任务的资源 ID。 | 字符串 (必需) |
OverrideTaskStepProperties
名称 | 说明 | 值 |
---|---|---|
参数 | 获取或设置在以下情况下使用的重写参数的集合 执行生成步骤。 |
Argument[] |
contextPath | 必须对其运行进行排队的源上下文。 | string |
文件 | 运行必须对其排队的文件。 | string |
目标 | docker 生成的目标生成阶段的名称。 | string |
updateTriggerToken | 将附加到基础映像触发器 Webhook 的 Base64 编码更新触发器令牌。 | string |
值 | 运行 Task 时可传递的可重写值的集合。 | SetValue[] |
Terraform (AzAPI 提供程序) 资源定义
可以使用面向以下操作部署 registries/taskRuns 资源类型:
- 资源组
有关每个 API 版本中已更改属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ContainerRegistry/registries/taskRuns 资源,请将以下 Terraform 添加到模板。
resource "azapi_resource" "symbolicname" {
type = "Microsoft.ContainerRegistry/registries/taskRuns@2019-06-01-preview"
name = "string"
location = "string"
parent_id = "string"
identity {
type = "string"
identity_ids = []
}
body = jsonencode({
properties = {
forceUpdateTag = "string"
runRequest = {
agentPoolName = "string"
isArchiveEnabled = bool
logTemplate = "string"
type = "string"
// For remaining properties, see RunRequest objects
}
}
})
}
RunRequest 对象
设置 type 属性以指定对象的类型。
对于 DockerBuildRequest,请使用:
type = "DockerBuildRequest"
agentConfiguration = {
cpu = int
}
arguments = [
{
isSecret = bool
name = "string"
value = "string"
}
]
credentials = {
customRegistries = {}
sourceRegistry = {
loginMode = "string"
}
}
dockerFilePath = "string"
imageNames = [
"string"
]
isPushEnabled = bool
noCache = bool
platform = {
architecture = "string"
os = "string"
variant = "string"
}
sourceLocation = "string"
target = "string"
timeout = int
对于 EncodedTaskRunRequest,请使用:
type = "EncodedTaskRunRequest"
agentConfiguration = {
cpu = int
}
credentials = {
customRegistries = {}
sourceRegistry = {
loginMode = "string"
}
}
encodedTaskContent = "string"
encodedValuesContent = "string"
platform = {
architecture = "string"
os = "string"
variant = "string"
}
sourceLocation = "string"
timeout = int
values = [
{
isSecret = bool
name = "string"
value = "string"
}
]
对于 FileTaskRunRequest,请使用:
type = "FileTaskRunRequest"
agentConfiguration = {
cpu = int
}
credentials = {
customRegistries = {}
sourceRegistry = {
loginMode = "string"
}
}
platform = {
architecture = "string"
os = "string"
variant = "string"
}
sourceLocation = "string"
taskFilePath = "string"
timeout = int
values = [
{
isSecret = bool
name = "string"
value = "string"
}
]
valuesFilePath = "string"
对于 TaskRunRequest,请使用:
type = "TaskRunRequest"
overrideTaskStepProperties = {
arguments = [
{
isSecret = bool
name = "string"
value = "string"
}
]
contextPath = "string"
file = "string"
target = "string"
updateTriggerToken = "string"
values = [
{
isSecret = bool
name = "string"
value = "string"
}
]
}
taskId = "string"
属性值
registries/taskRuns
名称 | 说明 | Value |
---|---|---|
type | 资源类型 | “Microsoft.ContainerRegistry/registries/taskRuns@2019-06-01-preview” |
name | 资源名称 | 字符串 (必需) |
location | 资源的位置 | string |
parent_id | 此资源的父资源的 ID。 | 类型为:注册表的资源的 ID |
标识 | 资源的标识。 | IdentityProperties |
properties | 与任务运行关联的属性,即运行的请求和结果 | TaskRunProperties |
IdentityProperties
名称 | 说明 | Value |
---|---|---|
type | 标识类型。 | “SystemAssigned” “SystemAssigned,UserAssigned” “UserAssigned” |
identity_ids | 与资源关联的用户标识列表。 用户标识 字典键引用将采用以下格式的 ARM 资源 ID: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/ providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'。 |
用户标识 ID 的数组。 |
TaskRunProperties
名称 | 说明 | 值 |
---|---|---|
forceUpdateTag | 如何在运行请求配置未更改的情况下强制重新运行 | string |
runRequest | 运行) 的请求 (参数 | RunRequest |
RunRequest
名称 | 说明 | 值 |
---|---|---|
agentPoolName | 运行的专用代理池。 | string |
isArchiveEnabled | 该值指示是否为运行启用存档。 | bool |
logTemplate | 描述运行日志项目的存储库和标记信息的模板。 | string |
type | 设置对象类型 | DockerBuildRequest EncodedTaskRunRequest FileTaskRunRequest TaskRunRequest (必需) |
DockerBuildRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “DockerBuildRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
参数 | 在执行运行时要使用的重写参数的集合。 | Argument[] |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
dockerFilePath | 相对于源位置的 Docker 文件路径。 | 字符串 (必需) |
imageNames | 完全限定的映像名称,包括存储库和标记。 | string[] |
isPushEnabled | 此属性的值指示是否应将生成的映像推送到注册表。 | bool |
noCache | 此属性的值指示是否启用图像缓存。 | bool |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
目标 | Docker 生成的目标生成阶段的名称。 | string |
timeout | 运行超时(以秒为单位)。 | int |
AgentProperties
名称 | 说明 | 值 |
---|---|---|
cpu | 运行所需的内核数的 CPU 配置。 | int |
参数
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示参数是否表示机密并想要从生成日志中删除的标志。 | bool |
name | 参数的名称。 | 字符串 (必需) |
值 | 参数的值。 | 字符串 (必需) |
凭据
名称 | 说明 | 值 |
---|---|---|
customRegistries | 介绍用于访问其他自定义注册表的凭据参数。 密钥 字典项的 注册表登录服务器 (myregistry.azurecr.io) 和 项的值将是用于访问注册表的注册表凭据。 |
object |
sourceRegistry | 介绍用于访问源注册表的凭据参数。 | SourceRegistryCredentials |
SourceRegistryCredentials
名称 | 说明 | 值 |
---|---|---|
loginMode | 确定源注册表登录范围的身份验证模式。 源注册表的凭据 将使用给定的范围生成。 这些凭据将用于登录 运行期间的源注册表。 |
“Default” "None" |
PlatformProperties
名称 | 说明 | 值 |
---|---|---|
体系结构 | OS 体系结构。 | "386" “amd64” “arm” “arm64” “x86” |
os | 运行所需的操作系统类型。 | “Linux” “Windows” (必需) |
variant | CPU 的变体。 | “v6” “v7” “v8” |
EncodedTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “EncodedTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
encodedTaskContent | 模板/定义文件内容的 Base64 编码值。 | 字符串 (必需) |
encodedValuesContent | 参数/值文件内容的 Base64 编码值。 | string |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可以传递的可重写值的集合。 | SetValue[] |
SetValue
名称 | 说明 | 值 |
---|---|---|
isSecret | 指示值是否表示机密的标志。 | bool |
name | 可重写值的名称。 | 字符串 (必需) |
值 | 可重写的值。 | 字符串 (必需) |
FileTaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “FileTaskRunRequest” (必需) |
agentConfiguration | 运行代理的计算机配置。 | AgentProperties |
凭据 | 描述调用此运行时将使用的一组凭据的属性。 | 凭据 |
平台 | 必须对其执行运行的平台属性。 | PlatformProperties (必需) |
sourceLocation | URL (源上下文的绝对或相对) 。 它可以是 tar 或 git 存储库的 URL。 如果它是相对 URL,则应从调用 listBuildSourceUploadUrl API 获取相对路径。 |
string |
taskFilePath | 相对于源的模板/定义文件路径。 | 字符串 (必需) |
timeout | 运行超时(以秒为单位)。 | int |
值 | 运行任务时可以传递的可重写值的集合。 | SetValue[] |
valuesFilePath | 相对于源的值/参数文件路径。 | string |
TaskRunRequest
名称 | 说明 | Value |
---|---|---|
type | 运行请求的类型。 | “TaskRunRequest” (必需) |
overrideTaskStepProperties | 运行 Task 时可传递的可重写参数集。 | OverrideTaskStepProperties |
taskId | 必须对其运行排队的任务的资源 ID。 | 字符串 (必需) |
OverrideTaskStepProperties
名称 | 说明 | 值 |
---|---|---|
参数 | 获取或设置在以下情况下要使用的替代参数的集合 执行生成步骤。 |
Argument[] |
contextPath | 必须对其运行进行排队的源上下文。 | string |
文件 | 必须对其运行进行排队的文件。 | string |
目标 | Docker 生成的目标生成阶段的名称。 | string |
updateTriggerToken | Base64 编码的更新触发器令牌,该令牌将与基础映像触发器 Webhook 一起附加。 | string |
值 | 运行 Task 时可传递的可重写值的集合。 | SetValue[] |
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈