New-AzContainerInstanceInitDefinitionObject
Create a in-memory object for InitContainerDefinition
Syntax
New-AzContainerInstanceInitDefinitionObject
-Name <String>
[-Command <String[]>]
[-EnvironmentVariable <IEnvironmentVariable[]>]
[-Image <String>]
[-VolumeMount <IVolumeMount[]>]
[<CommonParameters>]
Description
Create a in-memory object for InitContainerDefinition
Examples
Example 1: Set up the init container definition
New-AzContainerInstanceInitDefinitionObject -Name "initDefinition" -Command "/bin/sh -c myscript.sh"
Name
----
initDefinition
This command sets up the init container definition with command /bin/sh -c myscript.sh
Parameters
-Command
The command to execute within the init container in exec form.
Type: | String[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-EnvironmentVariable
The environment variables to set in the init container. To construct, see NOTES section for ENVIRONMENTVARIABLE properties and create a hash table.
Type: | IEnvironmentVariable[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Image
The image of the init container.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
The name for the init container.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-VolumeMount
The volume mounts available to the init container. To construct, see NOTES section for VOLUMEMOUNT properties and create a hash table.
Type: | IVolumeMount[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Outputs
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
Azure PowerShell