EADDRNOTAVAIL when setting host with docker #465

bufke opened this Issue May 28, 2015 · 8 comments


None yet

3 participants

bufke commented May 28, 2015

I'm trying to set the host so that I can use xmpp (based on #302). When set to the web interface works fine while xmpp does not. When I set to the correct domain I get

app_1 | 
app_1 | events.js:72
app_1 |         throw er; // Unhandled 'error' event
app_1 |               ^
app_1 | Error: listen EADDRNOTAVAIL
app_1 |     at errnoException (net.js:905:11)
app_1 |     at Server._listen2 (net.js:1024:19)
app_1 |     at listen (net.js:1065:10)
app_1 |     at net.js:1147:9
app_1 |     at asyncCallback (dns.js:68:16)
app_1 |     at Object.onanswer [as oncomplete] (dns.js:121:9)

I'm using docker-compose with the provided fig.yml file.

bufke commented May 29, 2015

As a workaround I was able to run without docker - just running node and mongo locally.

@bufke bufke changed the title from EADDRNOTAVAIL when setting host to EADDRNOTAVAIL when setting host with docker May 29, 2015
hhaidar commented Jun 10, 2015

Is this still an issue?

bufke commented Jun 10, 2015

I updated to 0.4.0 and tried again. Same settings as a known working instance (without docker). Instead of getting an error I get no output now.

app_1 |
app_1 | > lets-chat@0.4.0 prestart /usr/src/app
app_1 | > migroose
app_1 |

I will play around with it more latter. Settings file http://pastebin.com/VGAVxVDq


Hi @bufke,

Could you try our new official Docker image? It's available on Docker Hub here: https://registry.hub.docker.com/u/sdelements/lets-chat/


bufke commented Jul 1, 2015

I tried the new one. Sorry it took so long. If this only affect me feel free to close since I'm happy with not using docker. But in the interest of making this easier for others:

app_1   | Release 0.4.0
app_1   | 
app_1   | events.js:85
app_1   |       throw er; // Unhandled 'error' event
app_1   |             ^
app_1   | Error: listen EADDRNOTAVAIL
app_1   |     at exports._errnoException (util.js:746:11)
app_1   |     at Server._listen2 (net.js:1139:19)
app_1   |     at listen (net.js:1182:10)
app_1   |     at net.js:1280:9
app_1   |     at GetAddrInfoReqWrap.asyncCallback [as callback] (dns.js:81:16)
app_1   |     at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:99:10)


  image: sdelements/lets-chat
    - mongo
    - ./certs:/opt/certs
    - 5000:5000
    - 5001:5001
    - 5222:5222
    LCB_HTTP_HOST: 'chat.mydomain.com'
    LCB_HTTP_PORT: 5000
    LCB_HTTPS_PORT: 5001
    LCB_HTTPS_KEY: key.pem
    LCB_HTTPS_CERT: certificate.pem
    LCB_XMPP_PORT: 5222
    LCB_XMPP_HOST: 'chat.mydomain.com'
    LCB_XMPP_TLS_KEY: /opt/certs/server.key
    LCB_XMPP_TLS_CERT: /opt/certs/server.crt

  image: mongo:latest

When I remove the environment variables it works in the web interface as expected.


@bufke there is no need to overrideLCB_HTTP_PORT.

This setting relates to the host of the network interface you wish the app to bind to - which is when using Docker.

bufke commented Jul 3, 2015

Removing port didn't change anything. Removing the LCB_HTTP_HOST setting makes it start. I kept LCB_XMPP_HOST set and xmpp seems to work.

Is there anything we could do to make this easier to run? I makes sense to me now but I could see it hard to know which settings need set to ensure XMPP works. If XMPP host setting is required perhaps having XMPP enabled without a host should error out. On the wiki page it doesn't mention the XMPP HOST setting - only domain.

@bufke bufke closed this Jul 3, 2015

@bufke woops, that was a typo - I meant LCB_HTTP_HOST.

XMPP_HOST was confusing, so it was renamed to XMPP_DOMAIN. This setting currently only affects what is displayed in the XMPP modal in the web interface.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment