mdarkness1988 / Rust-Server

Modified Rust Server from didstopia
MIT License
8 stars 19 forks source link

web ui #12

Open atheistics opened 5 years ago

atheistics commented 5 years ago

Hello...im having an issue with the web UI...by the way...this is amazing! Absolutely love the idea of running a gaming server on unraid. I am trying to access the WebUI: and can't seem to get it to open...i set the port to one I'm not using..it is 8283. I think the default was something like HTTP://[ipaddress]:[port] but I did it like http://ipaddress:port ... was I supposed to leave these in there "[" ? Thanks. Also...sorry I contacted you this way but I couldn't find another way.

mdarkness1988 commented 5 years ago

Hi. Contacting me like this is fine 😁

That port does not seem like a proper port for web sites. Try one of the following ports ... 80,81,8080,8181

mdarkness1988 commented 5 years ago

P.s HTTP://[ipaddress]:[port] is just so the webui button works to the correct address and portbut does not actually change the port of the game webui. You still need to change the UI port in the game server settings

sasjafor commented 5 years ago

Where would you change the UI port? I can't find the right config file. I tried setting the container variable but that didn't change and in the UnRAID container log i still see that it's trying to bind to 8080.

sasjafor commented 5 years ago

Ah, it seems that the port is hardcoded in the nginx config file. Thus the environment variable seems to be useless.

mdarkness1988 commented 5 years ago

It should over right it. I'm sure I have done it before as most routers requires port 8080 itself for its own settings

sasjafor commented 5 years ago

When I search for PORTFORWARD_WEB in your repo I can only find it in two files. start_rust.sh, where the port forwarding stuff happens and in the Dockerfile where it's initialised as empty, but to overwrite the nginx conf you would use that variable, right?

mdarkness1988 commented 5 years ago

Yh but the file that looks at the variable is inside a container that you can't access. It's inside the virtual os that the container is running and not the files that you have access to

mdarkness1988 commented 5 years ago

Any chance you can screen shot the files with the variables are and the port config settings just so I can work it out better. I will see what I can do and if it's a mess up on my end I can try to rectify it tonight or tomorrow?

sasjafor commented 5 years ago

I can bash into the running container, but I'd be glad if you could tell me the exact nginx file that is used for the webserver to avoid confusion.

mdarkness1988 commented 5 years ago

Let me have a look at it and get back to you. If I fix it first then expect and update notification :)

mdarkness1988 commented 5 years ago

I think I know how I got it working on the port required. First the docker must not run as host mode as connection. Leave it as the default settings it originally had. You much change both port settings for Web port, Web port forward to the desired one.

The container runs it as 8080 but it's leaves the container as the port you wanted.

Please test and get back in touch.

sasjafor commented 5 years ago

I changed the container to bridge mode (was just using your unraid template, so it was host before). Changed both port settings for the web port, but now it seems that my set port is used on both sides, container and to the outside.

image

mdarkness1988 commented 5 years ago

Is it running properly though? And I think it lies about the internal ports in bridge mode

mdarkness1988 commented 5 years ago

Now I thought about it what network mode can you choose from?

sasjafor commented 5 years ago

I can have host and bridge, and also I could choose custom docker nets. By default it was in host.

mdarkness1988 commented 5 years ago

Yh that's right as only host mode supports auto port forward