New-AzContainerInstanceInitDefinitionObject
Create a in-memory object for InitContainerDefinition
Syntax
Default (Default)
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.
Parameter properties
Type: | String[] |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-EnvironmentVariable
The environment variables to set in the init container. To construct, see NOTES section for ENVIRONMENTVARIABLE properties and create a hash table.
Parameter properties
Type: | |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Image
The image of the init container.
Parameter properties
Type: | String |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Name
The name for the init container.
Parameter properties
Type: | String |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | True |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-VolumeMount
The volume mounts available to the init container. To construct, see NOTES section for VOLUMEMOUNT properties and create a hash table.
Parameter properties
Type: | |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.