Azure Batch 算子¶
AzureBatchOperator¶
使用 AzureBatchOperator
在 Azure Batch 上触发任务
以下是使用此算子在 Azure Batch 上触发任务的示例
azure_batch_operator = AzureBatchOperator(
task_id="azure_batch",
batch_pool_id=POOL_ID,
batch_pool_vm_size="standard_d2s_v3",
batch_job_id="example-job",
batch_task_command_line="/bin/bash -c 'set -e; set -o pipefail; echo hello world!; wait'",
batch_task_id="example-task",
vm_node_agent_sku_id="batch.node.ubuntu 22.04",
vm_publisher="Canonical",
vm_offer="0001-com-ubuntu-server-jammy",
vm_sku="22_04-lts-gen2",
target_dedicated_nodes=1,
)