diff options
author | Christopher Baines <mail@cbaines.net> | 2020-10-22 12:09:46 +0100 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2020-10-22 12:09:46 +0100 |
commit | ec8cd66f5fed43882d35fbf5e81ad73b9bd1e11a (patch) | |
tree | d9b1868bab1c838d837020df17c966f0b68c5896 | |
parent | 952b30654d1eb95b2a56d609cf63000ced0c0281 (diff) | |
download | build-coordinator-ec8cd66f5fed43882d35fbf5e81ad73b9bd1e11a.tar build-coordinator-ec8cd66f5fed43882d35fbf5e81ad73b9bd1e11a.tar.gz |
Move the post-publish-behaviour inside the s3 publish hook
So that it'll run only if the narinfo on S3 is changed, because this should
prevent it running when the hook wouldn't change the narinfo on S3, because
one already exists.
-rw-r--r-- | guix-build-coordinator/hooks.scm | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/guix-build-coordinator/hooks.scm b/guix-build-coordinator/hooks.scm index 0b41e11..8339b4f 100644 --- a/guix-build-coordinator/hooks.scm +++ b/guix-build-coordinator/hooks.scm @@ -176,6 +176,12 @@ command-line-arguments)) #:times 6 #:delay 20) + + (when post-publish-hook + (post-publish-hook directory + narinfo-filename + nar-filename)) + (retry-on-error (lambda () (s3-cp s3-bucket @@ -186,11 +192,6 @@ #:times 6 #:delay 20)) - (when post-publish-hook - (post-publish-hook directory - narinfo-filename - nar-filename)) - (delete-file (string-append directory "/" narinfo-filename)) (delete-file (string-append directory "/" nar-filename)))))) |