# HG changeset patch # User Emmanuel Gil Peyrot # Date 1306098602 -7200 # Node ID 9360b78c7a5ba5bfe7ed4468287db7f1dcdf86b1 # Parent e0cd5ede76af663d8b88292e4e013a4c8285c0e7 Add WebHost configuration, and default it to both IPv6 and IPv4. diff --git a/avatar.js b/avatar.js --- a/avatar.js +++ b/avatar.js @@ -318,4 +318,4 @@ http.createServer(function (req, res) { } getVCard(jid, res); -}).listen(config.webPort); +}).listen(config.webPort, config.webHost); diff --git a/configuration.js b/configuration.js --- a/configuration.js +++ b/configuration.js @@ -33,9 +33,12 @@ config.port = 5347; // Root of the webservice, useful if you want to proxy it. config.webRoot = '^/avatar/'; -// It is the port on which the web service will listen. If you want a -// port < 1024, you have to start it as root, use a proxy or redirect -// it using a firewall like iptables. +// These are the host and the port on which the web service will +// listen. If you want IPv4 connection only, instead of both IPv4 and +// IPv6, replace '::' by '0.0.0.0'. If you want a port < 1024, you +// have to start it as root, use a proxy or redirect it using a +// firewall like iptables. +config.webHost = '::'; config.webPort = 8032; // Directory for the cache of the images.