Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chart: Allow AWS ECS Executor #38524

Merged
merged 2 commits into from
Jun 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions chart/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ cluster using the [Helm](https://helm.sh) package manager.
## Features

* Supported executors: ``LocalExecutor``, ``CeleryExecutor``, ``KubernetesExecutor``, ``LocalKubernetesExecutor``, ``CeleryKubernetesExecutor``
* Supported AWS executors with AWS provider version ``8.21.0+``:
* ``airflow.providers.amazon.aws.executors.batch.AwsBatchExecutor``
* ``airflow.providers.amazon.aws.executors.ecs.AwsEcsExecutor``
* Supported Airflow version: ``1.10+``, ``2.0+``
* Supported database backend: ``PostgreSQL``, ``MySQL``
* Autoscaling for ``CeleryExecutor`` provided by KEDA
Expand Down
4 changes: 3 additions & 1 deletion chart/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,9 @@
"LocalKubernetesExecutor",
"CeleryExecutor",
"KubernetesExecutor",
"CeleryKubernetesExecutor"
"CeleryKubernetesExecutor",
"airflow.providers.amazon.aws.executors.batch.AwsBatchExecutor",
"airflow.providers.amazon.aws.executors.ecs.AwsEcsExecutor"
jedcunningham marked this conversation as resolved.
Show resolved Hide resolved
]
},
"allowPodLaunching": {
Expand Down
24 changes: 23 additions & 1 deletion helm_tests/airflow_aux/test_basic_helm_chart.py
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,26 @@ def get_k8s_objs_with_image(obj: list[Any] | dict[str, Any]) -> list[dict[str, A
# Make sure that a command is not specified
assert "command" not in obj

@pytest.mark.parametrize(
"executor",
[
"LocalExecutor",
"LocalKubernetesExecutor",
"CeleryExecutor",
"KubernetesExecutor",
"CeleryKubernetesExecutor",
"airflow.providers.amazon.aws.executors.batch.AwsBatchExecutor",
"airflow.providers.amazon.aws.executors.ecs.AwsEcsExecutor",
],
)
def test_supported_executor(self, executor):
render_chart(
"test-basic",
{
"executor": executor,
},
)

def test_unsupported_executor(self):
with pytest.raises(CalledProcessError) as ex_ctx:
render_chart(
Expand All @@ -524,7 +544,9 @@ def test_unsupported_executor(self):
assert (
'executor must be one of the following: "LocalExecutor", '
'"LocalKubernetesExecutor", "CeleryExecutor", '
'"KubernetesExecutor", "CeleryKubernetesExecutor"' in ex_ctx.value.stderr.decode()
'"KubernetesExecutor", "CeleryKubernetesExecutor", '
'"airflow.providers.amazon.aws.executors.batch.AwsBatchExecutor", '
'"airflow.providers.amazon.aws.executors.ecs.AwsEcsExecutor"' in ex_ctx.value.stderr.decode()
)

@pytest.mark.parametrize(
Expand Down