Fork me on GitHub
#luminus
<
2016-04-29
>
thug.nasty01:04:34

curtissummers: interesting - it totally is not localhost/127.0.0.1:3000

thug.nasty01:04:50

java 47551 ahobo 173u IPv6 0xbbec77fd433f9b5f 0t0 TCP 10.4.132.136:3000 (LISTEN) java 47551 ahobo 177u IPv6 0xbbec77fd433fb0df 0t0 TCP 127.0.0.1:7000 (LISTEN)

curtis.summers01:04:13

@thug.nasty: hmm...what's your OS?

curtis.summers01:04:33

have anything strange in your /etc/hosts file that might explain this 10.4.132.136?

thug.nasty01:04:46

that’s address that got assigned to me at work

thug.nasty01:04:58

the address*

thug.nasty01:04:32

I ran lein run again and it was bound to my ip address

thug.nasty01:04:45

that my router assigned me

curtis.summers01:04:23

that is really strange....I'm looking now to see if there's a way for you specify the host you want it to listen to. Obviously the auto default is choosing the wrong "localhost"

curtis.summers01:04:27

Maybe @yogthos can shed some light on this.

thug.nasty01:04:33

I haven’t tried doing this on Windows - I wonder if it does the same thing.

curtis.summers01:04:28

Maybe there's something specifically on your machine that doesn't like trying to listen on the "any" host.

thug.nasty01:04:08

perhaps it should go with 127.0.0.1?

thug.nasty01:04:14

instead of 0.0.0.0?

thug.nasty01:04:00

i wonder if that if it’s bound to 0.0.0.0

curtis.summers01:04:00

I'm not really sure. I understand 0.0.0.0 to listen on all interfaces, but it looks like it's picking one.

thug.nasty01:04:10

it’s only accessible by the ip address of the machine

thug.nasty01:04:58

perhaps INADDR_ANY refers to any IP that the local machine has

curtis.summers01:04:29

Yes, so while 0.0.0.0 might not be routable, I would think that 0.0.0.0 should imply that 127.0.0.1 or localhost would work.

thug.nasty02:04:04

in my other project

thug.nasty02:04:08

I use clj-socket

thug.nasty02:04:12

and when I start the server

curtis.summers02:04:13

I've also seen the suggestion to refer to computername.local:3000

thug.nasty02:04:16

this is what I see

thug.nasty02:04:18

java 73006 ahobo 60u IPv6 0xbbec77fd2532eb7f 0t0 TCP *:8675 (LISTEN)

thug.nasty02:04:35

I believe that’s the desired result

thug.nasty02:04:19

and the create-server call in that code does nothing more that return (ServerSocket. port)

curtis.summers02:04:56

Yes, it's strange, and I'm not seeing the same behavior on linux.

yogthos02:04:29

yeah I've seen this before

yogthos02:04:08

if the external hostname isn't configured properly then 0.0.0.0 will fail to bind

curtis.summers02:04:19

Looks like you can set :host "127.0.0.1" in env/dev/resources/config.edn

yogthos02:04:42

yup that's the fix