{% extends "web/_base.html" %}
{% block title %}Welcome to debusine-server!{% endblock %}
{% block content %}
    <h1 class="mb-3">Welcome to debusine!</h1>
    <p>
        Debusine manages scheduling and distribution of Debian-related tasks to a
        distributed network of machines.
    </p>
    <p>
        It is under active development by <a href="https://www.freexian.com/">Freexian</a>
        with the intention of providing easy access to a range of packaging tools
        and distribution-wide experiments.
    </p>
    {% if user.is_authenticated %}
        <p>
            You are authenticated as <b>{{ user.username }}</b>.
        </p>
    {% endif %}
    <p>
        If it's your first time exploring Debusine, you can start from
        <a href="https://freexian-team.pages.debian.net/debusine/explanation/introduction.html#what-is-debusine">What
        is Debusine</a>
        for an introduction, or browse the index to the whole
        <a href="https://freexian-team.pages.debian.net/debusine/index.html">Debusine documentation</a>.
        You may want to
        <a href="https://freexian-team.pages.debian.net/debusine/howtos/set-up-debusine-client.html">set up debusine-client</a>
        if you have not already done so.
    </p>
    <h2>Workspaces</h2>
    <p>
        Work in Debusine happens in
        <a href="https://freexian-team.pages.debian.net/debusine/explanation/concepts.html#workspaces">Workspaces</a>,
        which own artifacts and work requests and provide access control.
    </p>
    <p>This is a list of available workspaces you can access:</p>
    {% include "web/_workspace-list.html" with workspace_list=workspace_list user=user only %}
    {% if user.is_authenticated %}
        <h2>Your latest work requests</h2>
        <p>
            <a href="https://freexian-team.pages.debian.net/debusine/explanation/concepts.html#work-requests">Work Requests</a>
            are how
            <a href="https://freexian-team.pages.debian.net/debusine/explanation/concepts.html#tasks">tasks</a>
            are scheduled to be processed by workers. Here you can see a list of your
            current and past work requests processed by Debusine.
        </p>
        {% if work_request_list %}
            {% include "web/_work_request-list.html" with work_request_list=work_request_list user=user only %}
        {% else %}
            <p>No work requests created by {{ user.username }}.</p>
        {% endif %}
    {% endif %}
{% endblock %}
