mirror of https://notabug.org/mthl/cuirass.git
http: Add 'port' keyword argument to 'run-cuirass-server'.
* src/cuirass/http.scm (run-cuirass-server): Add 'port' keyword argument.pull/3/head
parent
96be568de4
commit
b59b8e5567
|
@ -1,4 +1,4 @@
|
||||||
;;; http.scm -- HTTP API
|
;;;; http.scm -- HTTP API
|
||||||
;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org>
|
;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of Cuirass.
|
;;; This file is part of Cuirass.
|
||||||
|
@ -70,8 +70,8 @@
|
||||||
#:body (string-append "Resource not found: "
|
#:body (string-append "Resource not found: "
|
||||||
(uri->string (request-uri request)))))))
|
(uri->string (request-uri request)))))))
|
||||||
|
|
||||||
(define (run-cuirass-server db)
|
(define* (run-cuirass-server db #:key (port 8080))
|
||||||
(run-server url-handler
|
(run-server url-handler
|
||||||
'http ;server implementation
|
'http ;server implementation
|
||||||
'() ;implementation parameters
|
`(#:port ,port) ;implementation parameters
|
||||||
db)) ;state
|
db)) ;state
|
||||||
|
|
Loading…
Reference in New Issue