TaskContainerSettings Class
- java.
lang. Object - com.
azure. resourcemanager. batch. models. TaskContainerSettings
- com.
Implements
public final class TaskContainerSettings
implements JsonSerializable<TaskContainerSettings>
The container settings for a task.
Constructor Summary
| Constructor | Description |
|---|---|
| TaskContainerSettings() |
Creates an instance of Task |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
List<Container |
containerHostBatchBindMounts()
Get the container |
| String |
containerRunOptions()
Get the container |
|
static
Task |
fromJson(JsonReader jsonReader)
Reads an instance of Task |
| String |
imageName()
Get the image |
|
Container |
registry()
Get the registry property: This setting can be omitted if was already provided at pool creation. |
|
Json |
toJson(JsonWriter jsonWriter) |
| void |
validate()
Validates the instance. |
|
Task |
withContainerHostBatchBindMounts(List<ContainerHostBatchBindMountEntry> containerHostBatchBindMounts)
Set the container |
|
Task |
withContainerRunOptions(String containerRunOptions)
Set the container |
|
Task |
withImageName(String imageName)
Set the image |
|
Task |
withRegistry(ContainerRegistry registry)
Set the registry property: This setting can be omitted if was already provided at pool creation. |
|
Task |
withWorkingDirectory(ContainerWorkingDirectory workingDirectory)
Set the working |
|
Container |
workingDirectory()
Get the working |
Methods inherited from java.lang.Object
Constructor Details
TaskContainerSettings
public TaskContainerSettings()
Creates an instance of TaskContainerSettings class.
Method Details
containerHostBatchBindMounts
public List<ContainerHostBatchBindMountEntry> containerHostBatchBindMounts()
Get the containerHostBatchBindMounts property: If this array is null or be not present, container task will mount entire temporary disk drive in windows (or AZ_BATCH_NODE_ROOT_DIR in Linux). It won't' mount any data paths into container if this array is set as empty.
Returns:
containerRunOptions
public String containerRunOptions()
Get the containerRunOptions property: These additional options are supplied as arguments to the "docker create" command, in addition to those controlled by the Batch Service.
Returns:
fromJson
public static TaskContainerSettings fromJson(JsonReader jsonReader)
Reads an instance of TaskContainerSettings from the JsonReader.
Parameters:
Returns:
Throws:
imageName
public String imageName()
Get the imageName property: This is the full image reference, as would be specified to "docker pull". If no tag is provided as part of the image name, the tag ":latest" is used as a default.
Returns:
registry
public ContainerRegistry registry()
Get the registry property: This setting can be omitted if was already provided at pool creation.
Returns:
toJson
validate
public void validate()
Validates the instance.
withContainerHostBatchBindMounts
public TaskContainerSettings withContainerHostBatchBindMounts(List<ContainerHostBatchBindMountEntry> containerHostBatchBindMounts)
Set the containerHostBatchBindMounts property: If this array is null or be not present, container task will mount entire temporary disk drive in windows (or AZ_BATCH_NODE_ROOT_DIR in Linux). It won't' mount any data paths into container if this array is set as empty.
Parameters:
Returns:
withContainerRunOptions
public TaskContainerSettings withContainerRunOptions(String containerRunOptions)
Set the containerRunOptions property: These additional options are supplied as arguments to the "docker create" command, in addition to those controlled by the Batch Service.
Parameters:
Returns:
withImageName
public TaskContainerSettings withImageName(String imageName)
Set the imageName property: This is the full image reference, as would be specified to "docker pull". If no tag is provided as part of the image name, the tag ":latest" is used as a default.
Parameters:
Returns:
withRegistry
public TaskContainerSettings withRegistry(ContainerRegistry registry)
Set the registry property: This setting can be omitted if was already provided at pool creation.
Parameters:
Returns:
withWorkingDirectory
public TaskContainerSettings withWorkingDirectory(ContainerWorkingDirectory workingDirectory)
Set the workingDirectory property: A flag to indicate where the container task working directory is. The default is 'taskWorkingDirectory'.
Parameters:
Returns:
workingDirectory
public ContainerWorkingDirectory workingDirectory()
Get the workingDirectory property: A flag to indicate where the container task working directory is. The default is 'taskWorkingDirectory'.
Returns: