listen on host

This commit is contained in:
Evert Prants 2021-02-22 20:28:35 +02:00
parent c7ce387685
commit 38214f9d8a
Signed by: evert
GPG Key ID: 1688DA83D222D0B5
2 changed files with 6 additions and 3 deletions

View File

@ -1,7 +1,9 @@
# Server configuration # Server configuration
[server] [server]
# Port the server will run on # Port the server will listen on
port=8282 port=8282
# Hostname the server will listen on
host="localhost"
# Session key # Session key
session_key="Session" session_key="Session"
# Session secret (keep this a secret) # Session secret (keep this a secret)

View File

@ -91,8 +91,9 @@ module.exports = (args) => {
app.use(routes) app.use(routes)
app.listen(args.port, () => { const host = args.host || 'localhost'
console.log('Listening on 0.0.0.0:' + args.port) app.listen(args.port, host, () => {
console.log('Listening on %s:%s', host, args.port)
// Initialize the email transporter (if configured) // Initialize the email transporter (if configured)
initEmail() initEmail()