Skip to content

Commit

Permalink
Update Airflow template to use operation agnostic names (#1808)
Browse files Browse the repository at this point in the history
  • Loading branch information
akchinSTC committed Jun 22, 2021
1 parent 2974dc2 commit 5f3b491
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions elyra/templates/airflow/airflow_template.jinja2
Expand Up @@ -45,7 +45,7 @@ op_{{ operation.id|regex_replace }} = {{ operation.name }}(namespace='{{ namespa
{{ param }}={{ value }},
{% endfor %}
{% else %}
notebook_op_{{ operation.id|regex_replace }} = NotebookOp(name='{{ operation.notebook|regex_replace }}',
op_{{ operation.id|regex_replace }} = NotebookOp(name='{{ operation.notebook|regex_replace }}',
namespace='{{ namespace }}',
task_id='{{ operation.notebook|regex_replace }}',
notebook='{{ operation.filename }}',
Expand Down Expand Up @@ -78,12 +78,12 @@ notebook_op_{{ operation.id|regex_replace }} = NotebookOp(name='{{ operation.not
config_file="{{ kube_config_path }}",
dag=dag)
{% if operation.image_pull_policy %}
notebook_op_{{ operation.id|regex_replace }}.image_pull_policy = '{{ operation.image_pull_policy }}'
op_{{ operation.id|regex_replace }}.image_pull_policy = '{{ operation.image_pull_policy }}'
{% endif %}

{% if operation.parent_operations %}
{% for parent_operation in operation.parent_operations %}
notebook_op_{{ operation.id|regex_replace }} << notebook_op_{{ parent_operation|regex_replace }}
op_{{ operation.id|regex_replace }} << op_{{ parent_operation|regex_replace }}
{% endfor %}
{% endif %}
{% endfor %}

0 comments on commit 5f3b491

Please sign in to comment.