You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/container-instances/container-instances-reference-yaml.md
+25-91Lines changed: 25 additions & 91 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,28 +1,30 @@
1
1
---
2
2
title: YAML reference for container group
3
3
description: Reference for the YAML file supported by Azure Container Instances to configure a container group
4
-
ms.topic: article
5
-
ms.date: 11/11/2021
4
+
author: tomvcassidy
5
+
ms.topic: reference
6
+
ms.service: container-instances
7
+
services: container-instances
8
+
ms.author: tomcassidy
9
+
ms.date: 06/06/2022
6
10
---
7
11
8
12
# YAML reference: Azure Container Instances
9
13
10
-
This article covers the syntax and properties for the YAML file supported by Azure Container Instances to configure a [container group](container-instances-container-groups.md). Use a YAML file to input the group configuration to the [az container create][az-container-create] command in the Azure CLI.
14
+
This article covers the syntax and properties for the YAML file supported by Azure Container Instances to configure a [container group](container-instances-container-groups.md). Use a YAML file to input the group configuration to the [az container create][az-container-create] command in the Azure CLI.
11
15
12
-
A YAML file is a convenient way to configure a container group for reproducible deployments. It is a concise alternative to using a [Resource Manager template](/azure/templates/Microsoft.ContainerInstance/2019-12-01/containerGroups) or the Azure Container Instances SDKs to create or update a container group.
16
+
A YAML file is a convenient way to configure a container group for reproducible deployments. It's a concise alternative to using a [Resource Manager template](/azure/templates/Microsoft.ContainerInstance/2019-12-01/containerGroups) or the Azure Container Instances SDKs to create or update a container group.
13
17
14
18
> [!NOTE]
15
-
> This reference applies to YAML files for Azure Container Instances REST API version `2021-07-01`.
19
+
> This reference applies to YAML files for Azure Container Instances REST API version `2021-10-01`.
16
20
17
-
## Schema
21
+
## Schema
18
22
19
23
The schema for the YAML file follows, including comments to highlight key properties. For a description of the properties in this schema, see the [Property values](#property-values) section.
| type | enum | No | The type of identity used for the container group. The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the container group. - SystemAssigned, UserAssigned, SystemAssigned, UserAssigned, None |
183
180
| userAssignedIdentities | object | No | The list of user identities associated with the container group. The user identity dictionary key references will be Azure Resource Manager resource IDs in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. |
184
181
185
-
186
-
187
-
188
182
### ContainerGroupProperties object
189
183
190
184
| Name | Type | Required | Value |
@@ -202,19 +196,13 @@ The following tables describe the values you need to set in the schema.
202
196
| encryptionProperties | object | No | The encryption properties for a container group. - [EncryptionProperties object](#encryptionproperties-object) |
203
197
| initContainers | array | No | The init containers for a container group. - [InitContainerDefinition object](#initcontainerdefinition-object) |
204
198
205
-
206
-
207
-
208
199
### Container object
209
200
210
201
| Name | Type | Required | Value |
211
202
| ---- | ---- | ---- | ---- |
212
203
| name | string | Yes | The user-provided name of the container instance. |
213
204
| properties | object | Yes | The properties of the container instance. - [ContainerProperties object](#containerproperties-object) |
214
205
215
-
216
-
217
-
218
206
### ImageRegistryCredential object
219
207
220
208
| Name | Type | Required | Value |
@@ -225,9 +213,6 @@ The following tables describe the values you need to set in the schema.
225
213
| identity | string | No | The resource ID of the user or system-assigned managed identity used to authenticate. |
226
214
| identityUrl | string | No | The identity URL for the private registry. |
227
215
228
-
229
-
230
-
231
216
### IpAddress object
232
217
233
218
| Name | Type | Required | Value |
@@ -237,9 +222,6 @@ The following tables describe the values you need to set in the schema.
237
222
| ip | string | No | The IP exposed to the public internet. |
238
223
| dnsNameLabel | string | No | The Dns name label for the IP. |
239
224
240
-
241
-
242
-
243
225
### Volume object
244
226
245
227
| Name | Type | Required | Value |
@@ -250,28 +232,19 @@ The following tables describe the values you need to set in the schema.
250
232
| secret | object | No | The secret volume. |
251
233
| gitRepo | object | No | The git repo volume. - [GitRepoVolume object](#gitrepovolume-object) |
252
234
253
-
254
-
255
-
256
235
### ContainerGroupDiagnostics object
257
236
258
237
| Name | Type | Required | Value |
259
238
| ---- | ---- | ---- | ---- |
260
239
| logAnalytics | object | No | Container group log analytics information. - [LogAnalytics object](#loganalytics-object) |
261
240
262
-
263
-
264
-
265
241
### ContainerGroupSubnetIds object
266
242
267
243
| Name | Type | Required | Value |
268
244
| ---- | ---- | ---- | ---- |
269
245
| id | string | Yes | The identifier for a subnet. |
270
246
| name | string | No | The name of the subnet. |
271
247
272
-
273
-
274
-
275
248
### DnsConfiguration object
276
249
277
250
| Name | Type | Required | Value |
@@ -280,22 +253,20 @@ The following tables describe the values you need to set in the schema.
280
253
| searchDomains | string | No | The DNS search domains for hostname lookup in the container group. |
281
254
| options | string | No | The DNS options for the container group. |
282
255
283
-
284
256
### EncryptionProperties object
285
257
286
-
| Name| Type| Required| Value |
258
+
| Name| Type| Required| Value |
287
259
| ---- | ---- | ---- | ---- |
288
-
| vaultBaseUrl| string| Yes| The keyvault base url. |
289
-
| keyName| string| Yes| The encryption key name. |
290
-
| keyVersion| string| Yes| The encryption key version. |
260
+
| vaultBaseUrl| string| Yes| The keyvault base url. |
261
+
| keyName| string| Yes| The encryption key name. |
262
+
| keyVersion| string| Yes| The encryption key version. |
291
263
292
264
### InitContainerDefinition object
293
265
294
-
| Name| Type| Required| Value |
266
+
| Name| Type| Required| Value |
295
267
| ---- | ---- | ---- | ---- |
296
-
| name | string | Yes | The name for the init container. |
297
-
| properties | object | Yes | The properties for the init container. - [InitContainerPropertiesDefinition object](#initcontainerpropertiesdefinition-object)
298
-
268
+
| name | string | Yes | The name for the init container. |
269
+
| properties | object | Yes | The properties for the init container. - [InitContainerPropertiesDefinition object](#initcontainerpropertiesdefinition-object)
299
270
300
271
### ContainerProperties object
301
272
@@ -310,19 +281,13 @@ The following tables describe the values you need to set in the schema.
310
281
| livenessProbe | object | No | The liveness probe. - [ContainerProbe object](#containerprobe-object) |
311
282
| readinessProbe | object | No | The readiness probe. - [ContainerProbe object](#containerprobe-object) |
312
283
313
-
314
-
315
-
316
284
### Port object
317
285
318
286
| Name | Type | Required | Value |
319
287
| ---- | ---- | ---- | ---- |
320
288
| protocol | enum | No | The protocol associated with the port. - TCP or UDP |
321
289
| port | integer | Yes | The port number. |
322
290
323
-
324
-
325
-
326
291
### AzureFileVolume object
327
292
328
293
| Name | Type | Required | Value |
@@ -332,9 +297,6 @@ The following tables describe the values you need to set in the schema.
332
297
| storageAccountName | string | Yes | The name of the storage account that contains the Azure File share. |
333
298
| storageAccountKey | string | No | The storage account access key used to access the Azure File share. |
334
299
335
-
336
-
337
-
338
300
### GitRepoVolume object
339
301
340
302
| Name | Type | Required | Value |
@@ -343,8 +305,6 @@ The following tables describe the values you need to set in the schema.
343
305
| repository | string | Yes | Repository URL |
344
306
| revision | string | No | Commit hash for the specified revision. |
345
307
346
-
347
-
348
308
### LogAnalytics object
349
309
350
310
| Name | Type | Required | Value |
@@ -355,15 +315,14 @@ The following tables describe the values you need to set in the schema.
355
315
| logType | enum | No | The log type to be used. - ContainerInsights or ContainerInstanceLogs |
356
316
| metadata | object | No | Metadata for log analytics. |
357
317
358
-
359
318
### InitContainerPropertiesDefinition object
360
319
361
-
| Name| Type| Required| Value |
320
+
| Name| Type| Required| Value |
362
321
| ---- | ---- | ---- | ---- |
363
-
| image| string| No| The image of the init container. |
364
-
| command| array| No| The command to execute within the init container in exec form. - string |
365
-
| environmentVariables | array| No |The environment variables to set in the init container. - [EnvironmentVariable object](#environmentvariable-object)
366
-
| volumeMounts |array| No| The volume mounts available to the init container. - [VolumeMount object](#volumemount-object)
322
+
| image| string| No| The image of the init container. |
323
+
| command| array| No| The command to execute within the init container in exec form. - string |
324
+
| environmentVariables | array| No |The environment variables to set in the init container. - [EnvironmentVariable object](#environmentvariable-object)
325
+
| volumeMounts |array| No| The volume mounts available to the init container. - [VolumeMount object](#volumemount-object)
367
326
368
327
### ContainerPort object
369
328
@@ -372,9 +331,6 @@ The following tables describe the values you need to set in the schema.
372
331
| protocol | enum | No | The protocol associated with the port. - TCP or UDP |
373
332
| port | integer | Yes | The port number exposed within the container group. |
374
333
375
-
376
-
377
-
378
334
### EnvironmentVariable object
379
335
380
336
| Name | Type | Required | Value |
@@ -383,19 +339,13 @@ The following tables describe the values you need to set in the schema.
383
339
| value | string | No | The value of the environment variable. |
384
340
| secureValue | string | No | The value of the secure environment variable. |
385
341
386
-
387
-
388
-
389
342
### ResourceRequirements object
390
343
391
344
| Name | Type | Required | Value |
392
345
| ---- | ---- | ---- | ---- |
393
346
| requests | object | Yes | The resource requests of this container instance. - [ResourceRequests object](#resourcerequests-object) |
394
347
| limits | object | No | The resource limits of this container instance. - [ResourceLimits object](#resourcelimits-object) |
395
348
396
-
397
-
398
-
399
349
### VolumeMount object
400
350
401
351
| Name | Type | Required | Value |
@@ -404,9 +354,6 @@ The following tables describe the values you need to set in the schema.
404
354
| mountPath | string | Yes | The path within the container where the volume should be mounted. Must not contain colon (:). |
405
355
| readOnly | boolean | No | The flag indicating whether the volume mount is read-only. |
406
356
407
-
408
-
409
-
410
357
### ContainerProbe object
411
358
412
359
| Name | Type | Required | Value |
@@ -419,9 +366,6 @@ The following tables describe the values you need to set in the schema.
419
366
| successThreshold | integer | No | The success threshold. |
420
367
| timeoutSeconds | integer | No | The timeout seconds. |
421
368
422
-
423
-
424
-
425
369
### ResourceRequests object
426
370
427
371
| Name | Type | Required | Value |
@@ -430,9 +374,6 @@ The following tables describe the values you need to set in the schema.
430
374
| cpu | number | Yes | The CPU request of this container instance. |
431
375
| gpu | object | No | The GPU request of this container instance. - [GpuResource object](#gpuresource-object) |
432
376
433
-
434
-
435
-
436
377
### ResourceLimits object
437
378
438
379
| Name | Type | Required | Value |
@@ -441,18 +382,12 @@ The following tables describe the values you need to set in the schema.
441
382
| cpu | number | No | The CPU limit of this container instance. |
442
383
| gpu | object | No | The GPU limit of this container instance. - [GpuResource object](#gpuresource-object) |
443
384
444
-
445
-
446
-
447
385
### ContainerExec object
448
386
449
387
| Name | Type | Required | Value |
450
388
| ---- | ---- | ---- | ---- |
451
389
| command | array | No | The commands to execute within the container. - string |
452
390
453
-
454
-
455
-
456
391
### ContainerHttpGet object
457
392
458
393
| Name | Type | Required | Value |
@@ -476,7 +411,6 @@ The following tables describe the values you need to set in the schema.
476
411
| count | integer | Yes | The count of the GPU resource. |
477
412
| sku | enum | Yes | The SKU of the GPU resource. - K80, P100, V100 |
478
413
479
-
480
414
## Next steps
481
415
482
416
See the tutorial [Deploy a multi-container group using a YAML file](container-instances-multi-container-yaml.md).
0 commit comments