ContainerProperties Class
- java.
lang. Object - com.
azure. resourcemanager. containerinstance. fluent. models. ContainerProperties
- com.
Implements
public final class ContainerProperties
implements JsonSerializable<ContainerProperties>
The container instance properties.
Constructor Summary
| Constructor | Description |
|---|---|
| ContainerProperties() |
Creates an instance of Container |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
| List<String> |
command()
Get the command property: The commands to execute within the container instance in exec form. |
|
List<Environment |
environmentVariables()
Get the environment |
|
static
Container |
fromJson(JsonReader jsonReader)
Reads an instance of Container |
| String |
image()
Get the image property: The name of the image used to create the container instance. |
|
Container |
instanceView()
Get the instance |
|
Container |
livenessProbe()
Get the liveness |
|
List<Container |
ports()
Get the ports property: The exposed ports on the container instance. |
|
Container |
readinessProbe()
Get the readiness |
|
Resource |
resources()
Get the resources property: The resource requirements of the container instance. |
|
Security |
securityContext()
Get the security |
|
Json |
toJson(JsonWriter jsonWriter) |
| void |
validate()
Validates the instance. |
|
List<Volume |
volumeMounts()
Get the volume |
|
Container |
withCommand(List<String> command)
Set the command property: The commands to execute within the container instance in exec form. |
|
Container |
withEnvironmentVariables(List<EnvironmentVariable> environmentVariables)
Set the environment |
|
Container |
withImage(String image)
Set the image property: The name of the image used to create the container instance. |
|
Container |
withLivenessProbe(ContainerProbe livenessProbe)
Set the liveness |
|
Container |
withPorts(List<ContainerPort> ports)
Set the ports property: The exposed ports on the container instance. |
|
Container |
withReadinessProbe(ContainerProbe readinessProbe)
Set the readiness |
|
Container |
withResources(ResourceRequirements resources)
Set the resources property: The resource requirements of the container instance. |
|
Container |
withSecurityContext(SecurityContextDefinition securityContext)
Set the security |
|
Container |
withVolumeMounts(List<VolumeMount> volumeMounts)
Set the volume |
Methods inherited from java.lang.Object
Constructor Details
ContainerProperties
public ContainerProperties()
Creates an instance of ContainerProperties class.
Method Details
command
public List<String> command()
Get the command property: The commands to execute within the container instance in exec form.
Returns:
environmentVariables
public List<EnvironmentVariable> environmentVariables()
Get the environmentVariables property: The environment variables to set in the container instance.
Returns:
fromJson
public static ContainerProperties fromJson(JsonReader jsonReader)
Reads an instance of ContainerProperties from the JsonReader.
Parameters:
Returns:
Throws:
image
public String image()
Get the image property: The name of the image used to create the container instance.
Returns:
instanceView
public ContainerPropertiesInstanceView instanceView()
Get the instanceView property: The instance view of the container instance. Only valid in response.
Returns:
livenessProbe
public ContainerProbe livenessProbe()
Get the livenessProbe property: The liveness probe.
Returns:
ports
public List<ContainerPort> ports()
Get the ports property: The exposed ports on the container instance.
Returns:
readinessProbe
public ContainerProbe readinessProbe()
Get the readinessProbe property: The readiness probe.
Returns:
resources
public ResourceRequirements resources()
Get the resources property: The resource requirements of the container instance.
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<VolumeMount> volumeMounts()
Get the volumeMounts property: The volume mounts available to the container instance.
Returns:
withCommand
public ContainerProperties withCommand(List<String> command)
Set the command property: The commands to execute within the container instance in exec form.
Parameters:
Returns:
withEnvironmentVariables
public ContainerProperties withEnvironmentVariables(List<EnvironmentVariable> environmentVariables)
Set the environmentVariables property: The environment variables to set in the container instance.
Parameters:
Returns:
withImage
public ContainerProperties withImage(String image)
Set the image property: The name of the image used to create the container instance.
Parameters:
Returns:
withLivenessProbe
public ContainerProperties withLivenessProbe(ContainerProbe livenessProbe)
Set the livenessProbe property: The liveness probe.
Parameters:
Returns:
withPorts
public ContainerProperties withPorts(List<ContainerPort> ports)
Set the ports property: The exposed ports on the container instance.
Parameters:
Returns:
withReadinessProbe
public ContainerProperties withReadinessProbe(ContainerProbe readinessProbe)
Set the readinessProbe property: The readiness probe.
Parameters:
Returns:
withResources
public ContainerProperties withResources(ResourceRequirements resources)
Set the resources property: The resource requirements of the container instance.
Parameters:
Returns:
withSecurityContext
public ContainerProperties withSecurityContext(SecurityContextDefinition securityContext)
Set the securityContext property: The container security properties.
Parameters:
Returns:
withVolumeMounts
public ContainerProperties withVolumeMounts(List<VolumeMount> volumeMounts)
Set the volumeMounts property: The volume mounts available to the container instance.
Parameters:
Returns: