runtimejs / runtime

[not maintained] Lightweight JavaScript library operating system for the cloud
http://runtimejs.org
Apache License 2.0
1.93k stars 128 forks source link

Client and Server Problems #115

Closed RossComputerGuy closed 8 years ago

RossComputerGuy commented 8 years ago

I have an os using the eshttp library and I have it hosting a server, I can't connect to my server on my host pc. And The client doesn't see that a body exists. I am listening to port 80 and port 8080. Code: https://github.com/SpaceboyRoss01/basicos

facekapow commented 8 years ago

What port are you listening on? Because, unless you passed an extra port option to runtime start, the only port that passes from QEMU to the host is port 9000.

facekapow commented 8 years ago

Then instead of doing runtime start, you need to do runtime start --port 80 --port 8080. (btw, you should probably add information by commenting, editing doesn't make any notifictions)

RossComputerGuy commented 8 years ago

This error shows up when I run runtime start --port 80 --port 8080: qemu-system-x86_64: -net user,net=192.168.76.0/24,dhcpstart=192.168.76.9,hostfwd=udp::9000-:9000,hostfwd=tcp::9000-:9000,hostfwd=udp::80-:80,hostfwd=tcp::80-:80,hostfwd=udp::8080-:8080,hostfwd=tcp::8080-:8080: could not set up host forwarding rule 'tcp::80-:80' qemu-system-x86_64: -net user,net=192.168.76.0/24,dhcpstart=192.168.76.9,hostfwd=udp::9000-:9000,hostfwd=tcp::9000-:9000,hostfwd=udp::80-:80,hostfwd=tcp::80-:80,hostfwd=udp::8080-:8080,hostfwd=tcp::8080-:8080: Device 'user' could not be initialized

iefserge commented 8 years ago

@SpaceboyRoss01 I think it needs sudo privileges for port 80. Does it start like this runtime start --port 8080?

RossComputerGuy commented 8 years ago

It works, but I can't connect to it in Firefox.

iefserge commented 8 years ago

Just tried this example https://github.com/runtimejs/example-web-server/blob/master/index.js using port 8080 and runtime start --port 8080. Worked for me. Are you sure you're setting up server correctly?

RossComputerGuy commented 8 years ago

I figured it out.