allow for optional port/address binding configuration
This commit is contained in:
@ -7,7 +7,10 @@
|
||||
|
||||
(require hyrule.control [defmain])
|
||||
|
||||
(setv [ADDRESS PORT] ["127.0.0.1" 5000])
|
||||
(try
|
||||
(import srv-config [ADDRESS PORT])
|
||||
(except [ModuleNotFoundError]
|
||||
(setv [ADDRESS PORT] ["127.0.0.1" 5000])))
|
||||
|
||||
(defmain []
|
||||
(let [socket (socket AF_INET SOCK_STREAM)]
|
||||
|
Reference in New Issue
Block a user