blob: 8f5392b8385e881c6603588f0f3790d1263b9491 [file] [log] [blame]
:mod:`airflow.contrib.operators.ecs_operator`
=============================================
.. py:module:: airflow.contrib.operators.ecs_operator
Module Contents
---------------
.. py:class:: ECSOperator(task_definition, cluster, overrides, aws_conn_id=None, region_name=None, launch_type='EC2', group=None, placement_constraints=None, platform_version='LATEST', network_configuration=None, **kwargs)
Bases: :class:`airflow.models.BaseOperator`
Execute a task on AWS EC2 Container Service
:param task_definition: the task definition name on EC2 Container Service
:type task_definition: str
:param cluster: the cluster name on EC2 Container Service
:type cluster: str
:param overrides: the same parameter that boto3 will receive (templated):
http://boto3.readthedocs.org/en/latest/reference/services/ecs.html#ECS.Client.run_task
:type overrides: dict
:param aws_conn_id: connection id of AWS credentials / region name. If None,
credential boto3 strategy will be used
(http://boto3.readthedocs.io/en/latest/guide/configuration.html).
:type aws_conn_id: str
:param region_name: region name to use in AWS Hook.
Override the region_name in connection (if provided)
:type region_name: str
:param launch_type: the launch type on which to run your task ('EC2' or 'FARGATE')
:type launch_type: str
:param group: the name of the task group associated with the task
:type group: str
:param placement_constraints: an array of placement constraint objects to use for
the task
:type placement_constraints: list
:param platform_version: the platform version on which your task is running
:type platform_version: str
:param network_configuration: the network configuration for the task
:type network_configuration: dict
.. attribute:: ui_color
:annotation: = #f0ede4
.. attribute:: client
.. attribute:: arn
.. attribute:: template_fields
:annotation: = ['overrides']
.. method:: execute(self, context)
.. method:: _wait_for_task_ended(self)
.. method:: _check_success_task(self)
.. method:: get_hook(self)
.. method:: on_kill(self)