diff --git a/content/_index.md b/content/_index.md index fb00d2b..ae86f62 100644 --- a/content/_index.md +++ b/content/_index.md @@ -7,6 +7,16 @@ The forge suite is a collection of tools to automate tasks by tracking updates o forgehook can be hooked to forgebuild to trigger tasks automatically when updates are received, but both tools can be useful on their own and integrate with your own tooling. If either tool gets in your way instead of easing your life, this is considered a bug and should be addressed. +# Usecases + +## Multi-user CI/CD + +![Diagram showing the forge sending a webhook to the endpoint, which validates it then passes the information to forgehook, which notifies subscribers, triggering forgebuild tasks](multi-CI.png) + +## Solo, unprivileged CI/CD + +![Diagram showing the forge sending a webhook to the endpoint, which validates it then passes the information to forgebuild, triggering tasks](solo-CI.png) + # Motivations This project was started because popular CI/CD distributions (such as Drone CI or Gitlab CI) are very convoluted systems, deeply tied to an ecosystem. The forge suite aims to be more portable and to easily integrate into your own ecosystem. diff --git a/content/forgebuild.fr.md b/content/forgebuild.fr.md index 1050888..a0443ff 120000 --- a/content/forgebuild.fr.md +++ b/content/forgebuild.fr.md @@ -1 +1 @@ -../submodules/build/README.md \ No newline at end of file +../submodules/build/README.fr.md \ No newline at end of file diff --git a/content/multi-CI.png b/content/multi-CI.png new file mode 100644 index 0000000..9b2b4fc Binary files /dev/null and b/content/multi-CI.png differ diff --git a/content/solo-CI.png b/content/solo-CI.png new file mode 100644 index 0000000..67ca866 Binary files /dev/null and b/content/solo-CI.png differ diff --git a/content/status.fr.md b/content/status.fr.md index 5bbef3f..5ecaa80 100644 --- a/content/status.fr.md +++ b/content/status.fr.md @@ -1,4 +1,6 @@ +++ -title="Statut des tests" +title="Résultats des tests" template="status.html" +++ + +Ici tu trouveras les derniers résultats des tests pour la suite forge. Ils sont directement lancés sur le serveur après chaque commit. diff --git a/content/status.md b/content/status.md index 3aa2dd7..4db6b13 100644 --- a/content/status.md +++ b/content/status.md @@ -1,4 +1,6 @@ +++ -title="Tests status" +title="Tests results" template="status.html" +++ + +Here you can find the latest test results for the forge suite. They are run directly on this server, on every new commit. diff --git a/sass/custom.scss b/sass/custom.scss index f89eee0..d9606c0 100644 --- a/sass/custom.scss +++ b/sass/custom.scss @@ -19,3 +19,10 @@ td, th { .testrun > ul { list-style-type: none; } + +.widget-tests { + > h2 { + text-align: center; + text-decoration: underline; + } +} diff --git a/templates/project.html b/templates/project.html index 049ec78..4cbd880 100644 --- a/templates/project.html +++ b/templates/project.html @@ -3,9 +3,14 @@ {{ super() }} {% if page.extra.pipeline %} {% if page.extra.pipeline in config.extra.tests.pipelines %} +
+ {% else %} -

No such pipeline ({{ page.extra.pipeline }}) defined in config.extra.pipelines

+

No such pipeline ({{ page.extra.pipeline }}) defined in config.extra.pipelines

{% endif %} + {% else %} +

Test pipeline for project not defined in frontmatter (page.extra.pipeline).

{% endif %} {% endblock %} diff --git a/templates/status.html b/templates/status.html index 62c2225..21cb606 100644 --- a/templates/status.html +++ b/templates/status.html @@ -1,7 +1,15 @@ -{% extends "index.html" %}{% import "tests.html" as tests %} +{% extends "page.html" %}{% import "tests.html" as tests %} {% block title %}{{ page.title }}{% endblock title %} {% block main %} +{{ super() }} +{% if config.extra.tests.pipelines %} + +{% else %} +

No test pipeline configured in config.extra.tests.pipelines

+{% endif %} {% endblock main %} diff --git a/templates/tests.html b/templates/tests.html index 53d23b6..2d965a0 100644 --- a/templates/tests.html +++ b/templates/tests.html @@ -1,5 +1,5 @@ {% macro pipeline(directory, name) %} -

{{ name }}

+

{{ name }}

{% set latest = [] %} {% set data = [] %} {% for impl in config.extra.tests.pipelines[name].impl %} @@ -36,7 +36,7 @@ {% for impl in config.extra.tests.pipelines[name].impl %} {% set suite_index = loop.index0 %} -

{{ impl.name }}

+

{{ impl.name }}

{# This is a hack because we can't reverse a map (only arrays) #} {% set_global runs = [] %} {% for key, val in data[suite_index] %}{% set_global runs = runs | concat(with=key) %}{% endfor %}