Commit Graph

102 Commits

Author SHA1 Message Date
Mathieu Othacehe 17e8759efe
Optimize Jobs table. 2021-04-14 15:05:00 +02:00
Mathieu Othacehe 29dc6015a8
templates: Round build percentages.
* src/cuirass/templates.scm (specifications-table): Round percentages.
2021-04-12 12:28:04 +02:00
Mathieu Othacehe 7542d626dc
Add the evaluations absolute build summary.
* src/cuirass/database.scm (db-get-evaluations-absolute-summary): New
procedure.
* src/cuirass/http.scm (url-handler): Pass the evaluation absolute summary to
"evaluation-info-table".
* src/cuirass/templates.scm (evaluation-info-table): Adapt it.
* src/static/css/cuirass.css (job-abs): New section.
* tests/database.scm ("db-get-evaluations-absolute-summary"): New test.
2021-04-09 09:27:32 +02:00
Mathieu Othacehe d3d1f384a4
Fix display glitches.
* src/cuirass/templates.scm (specifications-table): Fix glitches.
* src/static/css/cuirass.css (job-val): New section.
* doc/cuirass.texi: Update it.
2021-04-08 15:42:07 +02:00
Mathieu Othacehe d86c4edee7
Add specification period support.
* src/sql/upgrade-4.sql: New file.
* Makefile.am (dist_sql_DATA): Add it.
* src/schema.sql (Specifications)[period]: New field.
* src/cuirass/base.scm (process-specs): Honor the specification period.
* src/cuirass/database.scm (db-get-time-since-previous-build): Rename it into ...
(db-get-time-since-previous-eval): ... this new procedure.
* src/cuirass/specification.scm (<specification>)[period]: New field.
(specification->sexp, sexp->specification): Adapt accordingly.
* src/cuirass/templates.scm (specification-edit): Ditto.
* tests/database.scm ("db-get-time-since-previous-build"): Remame it into ...
("db-get-time-since-previous-eval"): ... this new procedure.
2021-04-08 15:37:43 +02:00
Mathieu Othacehe 245d0b5e5a
Add a jobs toggle button.
* src/cuirass/database.scm (db-get-specifications-summary): Return the latest
evaluation.
* src/cuirass/templates.scm (specifications-table): Add a monitor and a toggle
button.
2021-04-08 13:49:02 +02:00
Mathieu Othacehe 0ba0786741
Add specification job summary.
* src/cuirass/database.scm (db-get-specifications-summary): New procedure.
* tests/database.scm ("db-get-specifications-summary"): New test.
* src/cuirass/templates.scm (specifications-table): Add a summary argument.
* src/cuirass/http.scm (url-handler): Adapt it.
2021-04-08 11:56:37 +02:00
Mathieu Othacehe 065dbea573
Add a spinner to dashboard page.
* src/cuirass/templates.scm (evaluation-dashboard): Add a spinner.
2021-04-08 09:17:20 +02:00
Mathieu Othacehe ec0be96407
Add dashboard display.
* src/cuirass/http.scm (url-handler): New "/eval/id/dashboard" route.
* src/cuirass/templates.scm (evaluation-dashboard): New procedure.
* src/static/css/cuirass.css (content-fixed-margin, dashboard, div.tooltip):
New sections.
2021-04-07 11:47:48 +02:00
Mathieu Othacehe 63ce1c940b
Add d3.js support.
* src/static/js/d3.v6.min.js: New file.
* Makefile.am (dist_js_DATA): Add it.
* src/cuirass/http.scm (%file-white-list): Add it.
* src/cuirass/templates.scm (html-page): Add it.
2021-04-06 15:27:58 +02:00
Mathieu Othacehe eb94e7da6a
Add a footer margin. 2021-03-27 10:42:46 +01:00
Mathieu Othacehe 7c5b788029
Improve footer display. 2021-03-27 10:38:36 +01:00
Mathieu Othacehe a0d42b171f
Add a footer.
* src/cuirass/templates.scm (html-page): Add a footer.
* src/static/css/cuirass.css (body, footer): New sections.
2021-03-26 21:45:03 +01:00
Mathieu Othacehe c3a9e9c79f
Add pagination button on evaluation page. 2021-03-25 11:48:42 +01:00
Mathieu Othacehe 1ed9360108
Add table order buttons. 2021-03-25 10:31:38 +01:00
Mathieu Othacehe 48f630f9f7
Add builds per machine metric table. 2021-03-23 09:54:07 +01:00
Mathieu Othacehe 2efa062a4a
Update copyrights. 2021-03-22 18:31:41 +01:00
Mathieu Othacehe 9fbf6991fa
Add build parameter edition field. 2021-03-21 15:52:49 +01:00
Mathieu Othacehe 8379c803dc
Add form validation. 2021-03-12 10:53:05 +01:00
Mathieu Othacehe b24d55e368
Add specification creation and edition pages. 2021-03-11 19:31:35 +01:00
Mathieu Othacehe 2841bf3ba0
Remove admin section.
* src/cuirass/http.scm (url-handler): Remove admin section.
* src/cuirass/templates.scm (specifications-table): Remove optional admin
argument.
2021-03-11 08:10:51 +01:00
Mathieu Othacehe d521ec7bbf
Improve action button text.
* src/cuirass/templates.scm (evaluation-info-table): Improve action button text.
2021-03-09 19:05:32 +01:00
Mathieu Othacehe 21426073c1
Fix action list display.
* src/cuirass/templates.scm (evaluation-info-table): Fix action list display.
2021-03-09 19:01:29 +01:00
Mathieu Othacehe 6c5da97d46
Add evaluation retry & cancel support.
* src/cuirass/http.scm (url-handler): Add "/admin/evaluation/<id>/cancel" and
"admin/evaluation/<id>/retry" routes.
* src/cuirass/templates.scm (evaluation-info-table): Add "Cancel pending
builds" and "Retry" buttons.
2021-03-09 18:57:07 +01:00
Mathieu Othacehe 325edf2ffa
Rewrite evaluation. 2021-03-05 09:08:15 +01:00
Mathieu Othacehe 422de6c3e2
Remove favicon in SVG format.
* src/static/images/icon.svg: Remove it.
* src/cuirass/http.scm (%file-white-list): Remove "images/icon.svg".
* src/cuirass/templates.scm (html-page): Remove icon.svg link.
2021-02-19 19:25:11 +01:00
Mathieu Othacehe 2ab6c4604d
Add favicon support.
* src/cuirass/http.scm (%file-white-list): Rename "logo.png" into "guix.png".
Add "icon.png" and "icon.svg".
* src/cuirass/templates.scm (html-page): Adapt it.
* src/static/images/logo.png: Rename it ...
* src/static/images/guix.png: ... into this file.
* src/static/images/icon.png: New file.
* src/static/images/icon.svg: New file.
2021-02-19 09:53:16 +01:00
Mathieu Othacehe b200ea8947
Add a lock icon for admin actions.
* src/cuirass/templates.scm (build-details, evaluation-info-table): Add lock
icons for admin actions.
2021-02-19 09:19:09 +01:00
Mathieu Othacehe efb140d3d5
Remove the evaluation restart dropdown arrow.
* src/cuirass/templates.scm: Remove the evaluation restart dropdown arrow.
* src/static/css/cuirass.css (no-dropdown-arrow): New rule.
2021-02-18 15:37:10 +01:00
Mathieu Othacehe 64151eee28
Add an evaluation restart button.
* src/cuirass/http.scm (url-handler): New route
"/admin/evaluation/<id>/restart".
* src/cuirass/templates.scm (evaluation-info-table): Add an evaluation restart
button.
2021-02-18 15:22:59 +01:00
Mathieu Othacehe 04185edba6
Allow unconditionnal build restart.
* src/cuirass/templates.scm (build-details): Allow unconditionnal build
restart.
2021-02-18 14:57:42 +01:00
Mathieu Othacehe 4e0152f7a4
Add a build restart button.
* src/cuirass/http.scm (url-handler): New route "/admin/build/<id>/restart".
* src/cuirass/template.scm (build-details): Add a "restart" button.
2021-02-18 14:53:52 +01:00
Mathieu Othacehe b191a2a5f6
Pick the first worker build.
* src/cuirass/templates.scm (machine-status): Pick the first worker build if
multiple builds are started on the same worker.
2021-02-10 18:27:06 +01:00
Mathieu Othacehe ac98f81671
Add Zabbix support. 2021-02-08 12:26:35 +01:00
Mathieu Othacehe 6bd940fc24
Add RSS link to the home page.
* src/cuirass/templates.scm (specifications-table): Add RSS link.
2021-02-02 14:11:55 +01:00
Mathieu Othacehe 4e98cb02dd
Add RSS link to the evaluation page.
* src/cuirass/templates.scm (evaluation-info-table): Add RSS link.
2021-02-02 14:09:35 +01:00
Mathieu Othacehe f6662298c9
Move weather icon next to build status icon.
* src/cuirass/templates.scm (build-details): Move the weather icon.
2021-02-01 19:02:27 +01:00
Mathieu Othacehe a57b066e4f
Add build history support.
* src/cuirass/database.scm (db-get-builds): Add "oldevaluation" filter.
* src/cuirass/templates.scm (build-details): Add "history" argument.
* src/cuirass/http.scm (url-handler): Adapt it.
2021-02-01 17:49:00 +01:00
Mathieu Othacehe f9a5cbe0dd
Add weather support in build details.
* src/cuirass/templates.scm (build-details): Display weather.
2021-02-01 15:15:13 +01:00
Mathieu Othacehe d7282c05c0
Add build weather support.
* src/cuirass/database.scm (build-weather): New macro.
(build-status->weather): New procedure.
(db-get-builds): Return the build weather using the new procedure.
* src/cuirass/http.scm (build->hydra-build): Also return the weather.
* src/cuirass/templates.scm (weather-class, weather-title): New procedures.
(build-eval-table): Display the weather.
* tests/database.scm ("db-get-build weather"): New tests.
* tests/http.scm (build-query-result): Adapt it.
2021-02-01 14:27:24 +01:00
Mathieu Othacehe b993f3d433
Truncate long lines.
* src/cuirass/templates (workers-status): Truncate long lines.
2021-01-30 20:50:51 +01:00
Mathieu Othacehe 4370acce19
Sort workers consistently.
* src/cuirass/templates.scm (workers-status): Sort workers consistently.
2021-01-30 18:10:31 +01:00
Mathieu Othacehe 6c0298e12c
Remove left-over procedure.
* src/cuirass/templates.scm (workers-status): Remove unused "build-row"
procedure.
2021-01-30 18:02:35 +01:00
Mathieu Othacehe 5f770638bb
Fix workers display.
* src/cuirass/templates.scm (workers-status): Handle the case where multiple
builds are started on a worker.
2021-01-30 16:55:22 +01:00
Mathieu Othacehe 158dd2bd42
Fix build duration display.
* src/cuirass/templates.scm (build-details): Fix build duration display.
2021-01-30 16:11:50 +01:00
Mathieu Othacehe 7a7c26c628
Sort machines consistently.
* src/cuirass/templates.scm (workers-status): Sort machines.
2021-01-30 15:54:29 +01:00
Mathieu Othacehe 1e8d075d70
Improve workers page.
* src/cuirass/templates.scm (workers-status): Improve display.
* src/cuirass/http.scm (url-handler): Adapt it.
2021-01-30 14:24:29 +01:00
Mathieu Othacehe cbc462679d
Switch to PostegreSQL. 2021-01-11 12:28:13 +01:00
Mathieu Othacehe ca7a7ca989
Add remote build support.
* src/cuirass/remote.scm: New file.
* src/cuirass/remote-server.scm: New file.
* src/cuirass/remote-worker.scm: New file.
* bin/remote-server.in: New file.
* bin/remote-worker.in: New file.
* Makefile.am (bin_SCRIPTS): Add new binaries,
(dist_pkgmodule_DATA): add new files,
(EXTRA_DIST): add new binaries,
(bin/remote-server, bin/remote-worker): new targets.
* .gitignore: Add new binaries.
* bin/cuirass.in (%options): Add "--build-remote" option,
(show-help): document it,
(main): honor it.
* src/cuirass/base.scm (with-build-offload-thread): New macro,
(%build-remote?, %build-offload-channel): new parameters,
(make-build-offload-thread): new procedure,
(build-derivations/offload): new procedure,
(restart-builds): use it to offload builds when %build-remote? is set,
(build-packages): ditto.
2021-01-06 21:06:04 +01:00
Mathieu Othacehe 930c2f315c
Do not allow full search on nix_name field.
Searching for something like "%a%" can take up to ten minutes. Remove the
usage of special characters "^" and "$" in queries. Instead, always add a "%"
character at the end of the query. Also add an index on the nix_name field.

Fixes: <https://issues.guix.gnu.org/43791>.

* src/sql/upgrade-13.sql: New file.
* Makefile.am (dist_sql_DATA): Add it.
* src/schema.sql (Builds_nix_name): New index.
* src/cuirass/database.scm (query->bind-arguments): Remove support for "^" and
"$" special characters. Instead make sure that the query does not contain any
"%" character and prefix the query by "%".
(db-get-builds-by-search): Remove an useless query nesting level.
* src/cuirass/templates.scm (search-form): Adapt the search help message
accordingly.
2020-10-05 14:54:06 +02:00