summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Isaac2023-07-27 18:19:20 +0100
committerArun Isaac2023-07-27 23:44:38 +0100
commit08b9dd6a9a5e80bc9e1679cfd88b06bd3956f4bb (patch)
tree6ecfab5f275728bc17bd53c0b5280c3933a5808c
parent8a8477df910bdc172f298666cf09a94e6ac81b36 (diff)
downloadguix-forge-08b9dd6a9a5e80bc9e1679cfd88b06bd3956f4bb.tar.gz
guix-forge-08b9dd6a9a5e80bc9e1679cfd88b06bd3956f4bb.tar.lz
guix-forge-08b9dd6a9a5e80bc9e1679cfd88b06bd3956f4bb.zip
gunicorn: Set default socket to Unix socket.
* guix/forge/gunicorn.scm (<gunicorn-app>): Add this-gunicorn-app self-reference. [sockets]: Make field thunked. Set default to Unix socket.
-rw-r--r--guix/forge/gunicorn.scm9
1 files changed, 6 insertions, 3 deletions
diff --git a/guix/forge/gunicorn.scm b/guix/forge/gunicorn.scm
index 70142f5..1ae7d6f 100644
--- a/guix/forge/gunicorn.scm
+++ b/guix/forge/gunicorn.scm
@@ -63,13 +63,16 @@
(define-record-type* <gunicorn-app>
gunicorn-app make-gunicorn-app
gunicorn-app?
+ this-gunicorn-app
(name gunicorn-app-name)
(package gunicorn-app-package)
(wsgi-app-module gunicorn-app-wsgi-app-module)
(sockets gunicorn-app-sockets
- (default (list (forge-ip-socket
- (ip "127.0.0.1")
- (port 8080)))))
+ (default (list (forge-unix-socket
+ (path (string-append "/var/run/gunicorn/"
+ (gunicorn-app-name this-gunicorn-app)
+ "/socket")))))
+ (thunked))
(workers gunicorn-app-workers
(default 1))
(environment-variables gunicorn-app-environment-variables