Commit graph

231 commits

Author SHA1 Message Date
Robur
e7b3e13597 Fix compilation 2023-03-13 15:25:52 +00:00
Robur
ae1d8c553f Show an error when parsing duniverse fails 2023-03-13 15:25:14 +00:00
a0539604dc treat mirage (>=4.2.0) unikernels as unikernels, since they have x-mirage-opam-lock-location in the opam file
fixes #151
2023-03-13 11:50:05 +00:00
Robur
92fb616980 Update omd to 2.0.0~alpha3 2023-03-13 11:41:59 +00:00
02dbe1af37 adapt to omd 2.0.0 alpha3, which adds a Table constructor 2023-03-10 15:48:04 +01:00
e9f6e1d577 /failed-builds: special case no failed builds
🥳
2022-11-09 12:12:54 +01:00
5722fccf31 Fix local hrefs
The id attribute needs the id name without '#' while in the anchor href
we need to prefix with '#'.
2022-11-08 10:09:06 +01:00
2f632fc4c3 duniverse package, version -> dir, content
See previous recent nomenclature commit
2022-11-08 10:06:48 +01:00
891aa882ef compare view: remove empty headings (starting with 0), restructure code 2022-11-07 20:44:43 +01:00
8caa98644f Nomenclature: duniverse dirs vs duniverse packages
We have duniverse (simple) directories and no version information.
2022-11-07 16:38:20 +01:00
8862440053 Compute difference in x-opam-monorepo-duniverse-dirs and display it in compare 2022-11-07 16:38:20 +01:00
3f3de027ce Merge pull request 'Classify a build as monitoring build if mirage-monitoring is in the dependency cone' (#144) from fix-monitoring into main
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/144
2022-11-07 11:36:09 +00:00
82ea9e2266 Also add charset=utf-8 for console and script 2022-11-04 15:05:02 +01:00
3914e718c3 Classify a build as monitoring build if mirage-monitoring is in the dependency cone 2022-11-04 14:51:58 +01:00
281e285673 add charset to various mime types 2022-11-04 14:19:16 +01:00
d1c0bcd015 Be less verbose about ASN.1 parse errors 2022-08-29 12:50:07 +02:00
7a9949fc5e Hook scripts must end in .sh, FreeBSD packaging
- Only hook scripts that end in .sh are executed.
- When packaging for FreeBSD, batch-viz.sh and visualizations.sh are
  installed with a .sample extension. Addresses #137
2022-08-26 18:23:23 +02:00
f4da9ad666 In Opamdiff.compare, do not figure out unchanged packages.
In the View.compare_builds (/compare/..), do not display
"XX opam packages unchanged".

The reasoning is that the diff view concerns:
(a) opam packages
(b) environment variables
(c) system packages

And we're only interested in what changed in each category. The list of
unchanged opam packages is not really of interest, but adds quite some noise to
the page.
2022-08-05 11:16:21 +02:00
e253848a15 Rely on the default error page triggering for 404s
It is not immediately obvious how to avoid the error handler making a
different 404 response when the application code returns an explicit 404
page. Since we were already replying "Resource not found" in all cases
except one where we reply "File not found" not much is lost by relying
on the error handler behavior.
2022-07-15 11:16:01 +02:00
234c7a0cb2 Refactor not found logic 2022-07-15 11:13:11 +02:00
9416e0552d error_handler: only show not found for `Not_Found
For all other error status codes we just pass on the suggested response.
2022-07-15 10:51:57 +02:00
rand00
f3d8eea546 Fixed unused param + simplification 2022-07-15 10:51:57 +02:00
rand00
ffc062727a Views: Cleanup 2022-07-15 10:51:57 +02:00
rand00
3e23b4a5bf Implemented general error-handler + Added special error-page for iframes/vizs 2022-07-15 10:51:57 +02:00
76f96b47b2 map_err and bind_lwt_err will be deprecated with lwt.5.6.0 2022-07-12 13:23:23 +02:00
cb43734b7b Refactor and address #127 2022-07-12 13:14:52 +02:00
rand00
148ddacbe8 Add tests for router/Link module 2022-07-12 13:14:52 +02:00
rand00
c533ea7c07 Made Builder_web.routes be a list of methods, routes and handlers - to become testable without depending on DB 2022-07-12 13:14:52 +02:00
rand00
93dc0d6d87 Made all links safe via a Links module 2022-07-12 13:14:52 +02:00
0be38475b7 builder-web: Inform expected version on wrong ver. (#121)
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/121
Co-authored-by: Reynir Björnsson <reynir@reynir.dk>
Co-committed-by: Reynir Björnsson <reynir@reynir.dk>
2022-06-22 08:20:29 +00:00
071183ff6c Add GZip support when we generate a tar archive (#119)
Fixes #116.

Co-authored-by: Romain Calascibetta <romain.calascibetta@gmail.com>
Co-authored-by: Reynir Björnsson <reynir@reynir.dk>
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/119
Co-authored-by: dinosaure <romain.calascibetta@gmail.com>
Co-committed-by: dinosaure <romain.calascibetta@gmail.com>
2022-06-21 15:17:50 +00:00
rand
5307a7b91a add builder-db verify-cache-dir command (#113)
Co-authored-by: rand00 <oth.rand@gmail.com>
Co-authored-by: Reynir Björnsson <reynir@reynir.dk>
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/113
Co-authored-by: rand <rand@r7p5.earth>
Co-committed-by: rand <rand@r7p5.earth>
2022-06-16 09:03:05 +00:00
09a180c3cd Automatic viz migration on builder-web startup (#111)
Co-authored-by: rand00 <oth.rand@gmail.com>
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/111
Co-authored-by: Reynir Björnsson <reynir@reynir.dk>
Co-committed-by: Reynir Björnsson <reynir@reynir.dk>
2022-06-08 10:18:46 +00:00
702d38a6cc Use Not found for missing visualizations 2022-04-22 12:41:55 +01:00
3de78b1113 Update to dream.1.0.0~alpha4
- Dream.path is deprecated. For now the deprecation is suppressed.

- Remove unused dream_svg.

- Remove datadir global. The datadir variable is in scope already, and
  global variables were removed in alpha3.

- Dream_tar.tar_response: flush before closing. It's unclear if this is
  necessary.

- Change Builder_web.add_routes to Builder_web.routes returning a list
  of routes, and in Builder_web_app construct the router.

- Builder_web.not_found is removed due to changes in Dream.router. It
  seems an error handler might be the way forward.
2022-04-22 12:37:01 +01:00
6190347401 use ignorelist to transmit the intention 2022-04-21 20:55:19 +02:00
rand
0f493e9b47 Removing trailing slashes (#80)
This PR solves the issue of there being both "<url>/" and "<url>" paths, that in the builder-web context shouldn't mean different things.

The slashes are now removed using a `Dream` middleware, and the request is redirected using a permanent redirect (that doesn't change the method used): https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Location

Notable changes:
* Trailing slashes from the hardcoded link urls were removed, as unneccesary redirects are then avoided.
* All links in `Views` were rewritten to be absolute instead of relative.
* As `Dream` deprecated `path` - `Utils.Path` was created containing some helpers for manipulating paths. *Note that `String.split_on_char` has a different semantics.*
* A blacklist `routeprefix_blacklist_when_removing_trailing_slash` was added, containing `Dream` route-prefixes to ignore.
* Only `GET` and `HEAD` requests are redirected.
* `redirect_parent` helper was rewritten using new `Utils.Path` functions to avoid brittle string manipulation + fixed the edgecase of redirecting to `/`.
* Added `Uri` dependency to make URL manipulation safer.

Co-authored-by: rand00 <oth.rand@gmail.com>
Co-authored-by: Reynir Björnsson <reynir@reynir.dk>
Reviewed-on: https://git.robur.io/robur/builder-web/pulls/80
Co-authored-by: rand <rand@r7p5.earth>
Co-committed-by: rand <rand@r7p5.earth>
2022-04-21 10:40:21 +00:00
rand00
010197d900 Builder_web: Fixed type-errors + usage of correct dream queries helper 2022-04-11 18:19:54 +02:00
rand00
8f173295ab Merge branch 'main' into redirect-job-and-build 2022-04-11 18:13:12 +02:00
a132a181c8 add ? before query parameters 2022-04-11 17:08:10 +02:00
3bee8a357d add query params to redirect 2022-04-11 16:54:28 +02:00
4c3a5986d6 Redirect /job to / and /job/:job/build to /job/:job
replaces #81
2022-04-11 16:23:45 +02:00
rand00
1207ddbf70 Merge branch 'main' into 20220329_passing_separate_cache-dir 2022-04-06 13:31:42 +02:00
rand
258ffbd979 Merge branch 'main' into 20220325_viz_descriptions 2022-03-30 10:26:00 +00:00
rand00
ab3be6ec8e builder-web: Added --cachedir CLI arg for staging new vizs 2022-03-29 22:27:24 +02:00
rand00
1827320f8c Builder_web: Removed boilerplate for generating vizs 2022-03-29 14:00:13 +02:00
rand00
ef253b7b87 Views: Added usage-descriptions on mouse-over on '?' below each visualzation (not mobile compatible) 2022-03-29 12:56:11 +02:00
rand00
d90cbea35c Views: Removed visual border from viz iframes + size fix 2022-03-23 20:38:22 +01:00
eef8e54776 Include more information on the front page, especially how unikernels can be executed. 2022-03-03 11:36:09 +01:00
Robur
9cf112a9ac Fix error when reading solo5 manifest
Also simplify solo5 manifest code.
2022-02-25 11:21:16 +00:00