aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2019-12-15 10:36:42 +0000
committerChristopher Baines <mail@cbaines.net>2019-12-15 10:36:42 +0000
commitb66f1ee96a096d44b43838b99a81529caa1de4d1 (patch)
tree24cbb24115831ba841885de9c6b3d40e8704aaa1
parentf05283b2ce6d80fd19efd998597eac01fc4f0508 (diff)
downloaddata-service-b66f1ee96a096d44b43838b99a81529caa1de4d1.tar
data-service-b66f1ee96a096d44b43838b99a81529caa1de4d1.tar.gz
Link to the build pages from the derivation page
-rw-r--r--guix-data-service/model/build.scm5
-rw-r--r--guix-data-service/web/view/html.scm11
2 files changed, 12 insertions, 4 deletions
diff --git a/guix-data-service/model/build.scm b/guix-data-service/model/build.scm
index 44fdc94..cf91acd 100644
--- a/guix-data-service/model/build.scm
+++ b/guix-data-service/model/build.scm
@@ -129,7 +129,8 @@ LIMIT 100"))
conn derivation-file-name)
(define query
"
-SELECT build_servers.url,
+SELECT build_servers.id,
+ build_servers.url,
latest_build_status.timestamp,
latest_build_status.status
FROM builds
@@ -140,7 +141,7 @@ INNER JOIN
FROM build_status
ORDER BY build_id, timestamp DESC
) AS latest_build_status
-ON latest_build_status.build_id = builds.id
+ ON latest_build_status.build_id = builds.id
INNER JOIN derivations_by_output_details_set
ON builds.derivation_output_details_set_id =
derivations_by_output_details_set.derivation_output_details_set_id
diff --git a/guix-data-service/web/view/html.scm b/guix-data-service/web/view/html.scm
index 3391073..f16f45f 100644
--- a/guix-data-service/web/view/html.scm
+++ b/guix-data-service/web/view/html.scm
@@ -581,10 +581,17 @@
,(build-status-span "")))
(map
(match-lambda
- ((build-server-url timestamp status)
+ ((build-server-id build-server-url timestamp status)
+ (peek build-server-id timestamp status)
`(div
(@ (class "text-center"))
- (div ,(build-status-span status))
+ (div
+ (a (@ (href
+ ,(simple-format
+ #f "/build-server/~A/build?derivation_file_name=~A"
+ build-server-id
+ (second derivation))))
+ ,(build-status-span status)))
(a (@ (style "display: inline-block; margin-top: 0.4em;")
(href ,(simple-format
#f "~Abuild/~A"