typicode / hotel

🏩 A simple process manager for developers. Start apps from your browser and access them using local domains
MIT License
9.98k stars 422 forks source link

Access through network computers? #141

Closed THPubs closed 8 years ago

THPubs commented 8 years ago

Hi, is it possible to access the apps using network computers when using Local dev domains? This will be very useful to test the app in different platforms. Normally, I use the machine's ip and the port to access my apps but since hotel randomize the port, it's not that easy. :smile:

typicode commented 8 years ago

Hi @THPubs,

I'm not sure it's possible to use dev domains this way.

That said, you can set port using --port. For example, hotel add 'cmd -p $PORT' --port 4000 ensures that it'll always start on port 4000.

I would suggest connecting to http://remote-ip:2000, you'll access hotel dashboard and it'll be easier to access other servers then.

You need to allow remote connections though:

  1. Change host to 0.0.0.0 in ~/.hotel/conf.json
  2. Restart hotel hotel stop && hotel start

Let me know if it worked for you.

THPubs commented 8 years ago

@typicode Cool thanks it worked! Substituting $PORT with the required port won't work but your method (Adding a separate --port flag to the hotel command) works like a charm :smile: