diff options
author | Ludovic Courtès <ludo@gnu.org> | 2020-09-26 22:39:32 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2020-09-29 21:56:26 +0200 |
commit | 118b6dbb46ff3376db7467301fe59673c042d220 (patch) | |
tree | bb142eeaeaa4f9b5f6cc2a42e6734884763865fa | |
parent | dabb00ffee94cea6e2fbd3b356eb57f5292fdb27 (diff) | |
download | guix-118b6dbb46ff3376db7467301fe59673c042d220.tar.gz guix-118b6dbb46ff3376db7467301fe59673c042d220.zip |
secret-service: Clarify the origin of messages.
* gnu/build/secret-service.scm (secret-service-send-secrets)
(secret-service-receive-secrets): Prefix messages by "secret service".
-rw-r--r-- | gnu/build/secret-service.scm | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/gnu/build/secret-service.scm b/gnu/build/secret-service.scm index 781651e90d..aafb1684b5 100644 --- a/gnu/build/secret-service.scm +++ b/gnu/build/secret-service.scm @@ -54,11 +54,14 @@ local PORT. If connect fails, sleep 1s and retry RETRY times." (lambda (key . args) (when (zero? retry) (apply throw key args)) - (format (current-error-port) "retrying connection~%") + (format (current-error-port) + "secret service: retrying connection [~a attempts left]~%" + (- retry 1)) (sleep 1) (loop (1- retry))))) - (format (current-error-port) "connected! sending files in ~s %~" + (format (current-error-port) + "secret service: connected; sending files in ~s~%" secret-root) (let* ((files (if secret-root (find-files secret-root) '())) (files-sizes-modes (map file->file+size+mode files)) @@ -82,11 +85,12 @@ Write them to the file system." (bind sock AF_INET INADDR_ANY port) (listen sock 1) (format (current-error-port) - "waiting for secrets on port ~a...~%" + "secret service: waiting for secrets on port ~a...~%" port) (match (accept sock) ((client . address) - (format (current-error-port) "client connection from ~a~%" + (format (current-error-port) + "secret service: client connection from ~a~%" (inet-ntop (sockaddr:fam address) (sockaddr:addr address))) (close-port sock) @@ -116,7 +120,8 @@ Write them to the file system." ('files ((files sizes modes) ...))) (for-each (lambda (file size mode) (format (current-error-port) - "installing file '~a' (~a bytes)...~%" + "secret service: \ +installing file '~a' (~a bytes)...~%" file size) (mkdir-p (dirname file)) (call-with-output-file file @@ -126,7 +131,7 @@ Write them to the file system." files sizes modes)) (_ (format (current-error-port) - "invalid secrets received~%") + "secret service: invalid secrets received~%") #f))) (let* ((port (wait-for-client port)) |