{% extends "base.html" %} {% load core_extras %} {% load staticfiles %} {% load tz %} {% block page_scripts %} {% endblock %} {% load guardian_tags %} {% block content %} {% get_obj_perms user for execution.task as "task_perms" %}

{% model_icon 'execution' %} {{ execution.task.name }} on {{ execution.environment.name }}

{% execution_status execution.status %} {% if 'execute_task' in task_perms %} Execute {% endif %} {% if 'change_task' in task_perms %} {% endif %} {% if 'execute_task' in task_perms %} Abort {% endif %}

{% model_icon 'user' %} {{ execution.user.get_full_name }}
{% if execution.time_start != None %}{{ execution.time_start|timezone:user.timezone }}{% else %}pending{% endif %}
{% for command in execution.commands.all %}
{{ command.command }} {% for role in command.roles.all %} {{ role.name }} {% endfor %}
{% for server in command.servers.all %}
{{ server.server.name }} ({{ server.server.host }})
{{ server.output }}
{% if server.time != None %} {% if server.status == server.SUCCESS %} finished in {{ server.time }} s {% else %} failed with code {{ server.return_code }} after {{ server.time }} s {% endif %} {% endif %}
{% endfor %}
{% endfor %}
{% if execution.time_end %}{{ execution.time_end|timezone:user.timezone }}{% endif %} {% if execution.time %}{{ execution.time }} s{% endif %}
{% endblock %}