trouble exposing a go app
my app is listening on 0.0.0.0:$PORT, the port is exposed in the dockerfile, and it's working locally but it seems it isn't exposed on railway.
23 Replies
Project ID:
5c0858c1-2ed6-476a-a131-80a111e5c11a
5c0858c1-2ed6-476a-a131-80a111e5c11a
oh my specialty
yes
what kind of go app? chi?
yes
do show me the code that listens
funky
":" + os.Getenv("PORT")
yes i know
i just like using sprintf
i'll try that though
Sprintf is pretty neat
yes
now it works
interesting
hehe
what changed
who knows
okay lmfao
not me, all I know if what does work
not specifying the IP just works, even for communication over the private ipv6 only network
this was in my other app
and it works on railway
idk at least it works now
this is the code I use, so I put it in railways docs
https://docs.railway.app/troubleshoot/fixing-common-errors#go--nethttp
ah
alright all good?
yep