Allow running in foreground
This commit is contained in:
parent
ef3e18931a
commit
7840e72e41
|
@ -100,7 +100,8 @@ make a Clack HTTP response that serves the appropriate image."
|
||||||
(404-response)))))
|
(404-response)))))
|
||||||
|
|
||||||
|
|
||||||
(defun start-server (&key (address "0.0.0.0") (port 5001) (captcha-directory #p"captcha/"))
|
(defun start-server (&key (address "0.0.0.0") (port 5001) (background 't)
|
||||||
|
(captcha-directory #p"captcha/"))
|
||||||
"Start the Kaptchapelo server, which takes captcha challenges from the given
|
"Start the Kaptchapelo server, which takes captcha challenges from the given
|
||||||
CAPTCHA-DIRECTORY. Challenges are made up of two files:
|
CAPTCHA-DIRECTORY. Challenges are made up of two files:
|
||||||
* A challenge PNG file (ex. bird.png)
|
* A challenge PNG file (ex. bird.png)
|
||||||
|
@ -110,4 +111,5 @@ Note that the The answer text-file should not contain a trailing newline."
|
||||||
(lambda (env)
|
(lambda (env)
|
||||||
(funcall #'server env captcha-directory))
|
(funcall #'server env captcha-directory))
|
||||||
:address address
|
:address address
|
||||||
:port port))
|
:port port
|
||||||
|
:use-thread background))
|
||||||
|
|
|
@ -7,4 +7,5 @@
|
||||||
;; Change captcha-directory’s path to your captchas
|
;; Change captcha-directory’s path to your captchas
|
||||||
:captcha-directory #p"~/.local/lib/quicklisp/local-projects/kaptchapelo/captcha/"
|
:captcha-directory #p"~/.local/lib/quicklisp/local-projects/kaptchapelo/captcha/"
|
||||||
:address "0.0.0.0"
|
:address "0.0.0.0"
|
||||||
:port 5001)
|
:port 5001
|
||||||
|
:background nil)
|
||||||
|
|
Ŝarĝante…
Reference in New Issue