diff options
Diffstat (limited to 'scripts/guix-data-service.in')
-rw-r--r-- | scripts/guix-data-service.in | 26 |
1 files changed, 20 insertions, 6 deletions
diff --git a/scripts/guix-data-service.in b/scripts/guix-data-service.in index 1a41bd4..dc6b432 100644 --- a/scripts/guix-data-service.in +++ b/scripts/guix-data-service.in @@ -37,6 +37,8 @@ (guix-data-service config) (guix-data-service database) (guix-data-service substitutes) + (guix-data-service poll-git-repository) + (guix-data-service model git-repository) (guix-data-service model guix-revision-package-derivation) (guix-data-service web server) (guix-data-service web controller) @@ -204,12 +206,24 @@ (start-substitute-query-threads) - (when (assoc-ref opts 'update-database) - (call-with-new-thread - (lambda () - (run-sqitch) - - (atomic-box-set! startup-completed #t)))) + (call-with-new-thread + (lambda () + (run-sqitch) + + (for-each + (lambda (git-repository-details) + (when (fifth git-repository-details) + (simple-format #t "starting thread to poll ~A (~A)\n" + (second git-repository-details) + (third git-repository-details)) + + (start-thread-to-poll-git-repository + (first git-repository-details)))) + (with-postgresql-connection + "poll-startup" + all-git-repositories)) + + (atomic-box-set! startup-completed #t))) ;; Provide some visual space between the startup output and the ;; server starting |