diff options
Diffstat (limited to 'templates/base')
-rw-r--r-- | templates/base/agl-base.jinja2 | 2 | ||||
-rw-r--r-- | templates/base/agl-callback-section.jinja2 | 9 | ||||
-rw-r--r-- | templates/base/agl-callback-subsection.jinja2 | 5 | ||||
-rw-r--r-- | templates/base/agl-callback.jinja2 | 11 |
4 files changed, 15 insertions, 12 deletions
diff --git a/templates/base/agl-base.jinja2 b/templates/base/agl-base.jinja2 index 07bf168..fddda12 100644 --- a/templates/base/agl-base.jinja2 +++ b/templates/base/agl-base.jinja2 @@ -4,7 +4,7 @@ {% include 'base/agl-metadata.jinja2' %} {% endblock %} {% if do_callback %} -{% include 'base/agl-callback.jinja2' %} +{% include 'base/agl-callback-section.jinja2' %} {% endif %} {%- block main %} device_type: {{ device_type }} diff --git a/templates/base/agl-callback-section.jinja2 b/templates/base/agl-callback-section.jinja2 new file mode 100644 index 0000000..44987b2 --- /dev/null +++ b/templates/base/agl-callback-section.jinja2 @@ -0,0 +1,9 @@ +{%- block notify -%} +notify: + criteria: + status: finished + callbacks: +{%-for callback_to in callback_to_list %} +{% include 'base/agl-callback-subsection.jinja2' %} +{%- endfor %} +{%- endblock %} diff --git a/templates/base/agl-callback-subsection.jinja2 b/templates/base/agl-callback-subsection.jinja2 new file mode 100644 index 0000000..c8c7db9 --- /dev/null +++ b/templates/base/agl-callback-subsection.jinja2 @@ -0,0 +1,5 @@ + - url: {{ callback_to.backend_fqdn }}/callback/lava/test?lab_name={{ callback_to.lab_name }}&status={STATUS}&status_string={STATUS_STRING} + method: POST + dataset: all + token: {{ callback_to.lab_token }} + content-type: json diff --git a/templates/base/agl-callback.jinja2 b/templates/base/agl-callback.jinja2 deleted file mode 100644 index b5d3e5e..0000000 --- a/templates/base/agl-callback.jinja2 +++ /dev/null @@ -1,11 +0,0 @@ -{%- block notify -%} -notify: - criteria: - status: finished - callbacks: - - url: {{ backend_fqdn }}/callback/lava/test?lab_name={{ lab_name }}&status={STATUS}&status_string={STATUS_STRING} - method: POST - dataset: all - token: {{ lab_token }} - content-type: json -{%- endblock %} |