diff options
-rw-r--r-- | guix-build-coordinator/coordinator.scm | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/guix-build-coordinator/coordinator.scm b/guix-build-coordinator/coordinator.scm index ad0a6a1..64a04c3 100644 --- a/guix-build-coordinator/coordinator.scm +++ b/guix-build-coordinator/coordinator.scm @@ -24,12 +24,15 @@ #:use-module (gcrypt random) #:use-module (guix derivations) #:use-module (guix-build-coordinator utils) + #:use-module (guix-build-coordinator config) #:use-module (guix-build-coordinator datastore) #:export (submit-build new-agent new-agent-password fetch-builds - agent-details)) + agent-details + + build-output-file-location)) (define* (submit-build datastore derivation-file #:key @@ -112,3 +115,10 @@ (allocated-builds (datastore-list-agent-builds datastore agent-id))) `(,@agent ; description (builds . ,(list->vector allocated-builds))))) + +(define (build-output-file-location datastore build-id output-name) + (let ((output (datastore-find-build-output datastore build-id output-name))) + (string-append (%config 'builds-dir) "/" + build-id "/outputs/" output-name "/" + (basename output) + ".nar.lz"))) |