InitContainerDefinition Class
- java.
lang. Object - com.
azure. resourcemanager. containerinstance. models. InitContainerDefinition
- com.
Implements
public final class InitContainerDefinition
implements JsonSerializable<InitContainerDefinition>
The init container definition.
Constructor Summary
Constructor | Description |
---|---|
InitContainerDefinition() |
Creates an instance of Init |
Method Summary
Modifier and Type | Method and Description |
---|---|
List<String> |
command()
Get the command property: The command to execute within the init container in exec form. |
List<Environment |
environmentVariables()
Get the environment |
static
Init |
fromJson(JsonReader jsonReader)
Reads an instance of Init |
String |
image()
Get the image property: The image of the init container. |
Init |
instanceView()
Get the instance |
String |
name()
Get the name property: The name for the init container. |
Security |
securityContext()
Get the security |
Json |
toJson(JsonWriter jsonWriter) |
void |
validate()
Validates the instance. |
List<Volume |
volumeMounts()
Get the volume |
Init |
withCommand(List<String> command)
Set the command property: The command to execute within the init container in exec form. |
Init |
withEnvironmentVariables(List<EnvironmentVariable> environmentVariables)
Set the environment |
Init |
withImage(String image)
Set the image property: The image of the init container. |
Init |
withName(String name)
Set the name property: The name for the init container. |
Init |
withSecurityContext(SecurityContextDefinition securityContext)
Set the security |
Init |
withVolumeMounts(List<VolumeMount> volumeMounts)
Set the volume |
Methods inherited from java.lang.Object
Constructor Details
InitContainerDefinition
public InitContainerDefinition()
Creates an instance of InitContainerDefinition class.
Method Details
command
public List
Get the command property: The command to execute within the init container in exec form.
Returns:
environmentVariables
public List
Get the environmentVariables property: The environment variables to set in the init container.
Returns:
fromJson
public static InitContainerDefinition fromJson(JsonReader jsonReader)
Reads an instance of InitContainerDefinition from the JsonReader.
Parameters:
Returns:
Throws:
image
public String image()
Get the image property: The image of the init container.
Returns:
instanceView
public InitContainerPropertiesDefinitionInstanceView instanceView()
Get the instanceView property: The instance view of the init container. Only valid in response.
Returns:
name
public String name()
Get the name property: The name for the init container.
Returns:
securityContext
public SecurityContextDefinition securityContext()
Get the securityContext property: The container security properties.
Returns:
toJson
validate
public void validate()
Validates the instance.
volumeMounts
public List
Get the volumeMounts property: The volume mounts available to the init container.
Returns:
withCommand
public InitContainerDefinition withCommand(List
Set the command property: The command to execute within the init container in exec form.
Parameters:
Returns:
withEnvironmentVariables
public InitContainerDefinition withEnvironmentVariables(List
Set the environmentVariables property: The environment variables to set in the init container.
Parameters:
Returns:
withImage
public InitContainerDefinition withImage(String image)
Set the image property: The image of the init container.
Parameters:
Returns:
withName
public InitContainerDefinition withName(String name)
Set the name property: The name for the init container.
Parameters:
Returns:
withSecurityContext
public InitContainerDefinition withSecurityContext(SecurityContextDefinition securityContext)
Set the securityContext property: The container security properties.
Parameters:
Returns:
withVolumeMounts
public InitContainerDefinition withVolumeMounts(List
Set the volumeMounts property: The volume mounts available to the init container.
Parameters:
Returns:
Applies to
Azure SDK for Java