Page 1 of 1

Set up for Freeciv-web

Posted: Fri Aug 25, 2023 3:18 pm
by jgauthier
I played FreeCiv a long, long time ago. I 'd like to play it again. I was looking at Freeciv-web and I noticed its requirements:
Freeciv - the Freeciv C server, which is checked out from the official Git repository, and patched to work with a WebSocket/JSON protocol. Implemented in C.

Freeciv-proxy - a WebSocket proxy which allows WebSocket clients in Freeciv-web to send socket requests to Freeciv servers. WebSocket requests are sent from Javascript in Freeciv-web to nginx, which then proxies the WebSocket messages to freeciv-proxy, which finally sends Freeciv socket requests to the Freeciv servers. Implemented in Python.
So it sounds like the bundled freeciv server has patches for Websocket communications.
But below that it mentioned freeciv-proxy which sounds like it proxies the websocket to standard freeciv communications.

Are BOTH required, or can I just use the proxy with the unpatched server?

Thanks for the clarification.

Re: Set up for Freeciv-web

Posted: Sat Aug 26, 2023 1:47 pm
by cazfi
jgauthier wrote: Fri Aug 25, 2023 3:18 pm I played FreeCiv a long, long time ago. I 'd like to play it again. I was looking at Freeciv-web and I noticed its requirements:
Freeciv - the Freeciv C server, which is checked out from the official Git repository, and patched to work with a WebSocket/JSON protocol. Implemented in C.

Freeciv-proxy - a WebSocket proxy which allows WebSocket clients in Freeciv-web to send socket requests to Freeciv servers. WebSocket requests are sent from Javascript in Freeciv-web to nginx, which then proxies the WebSocket messages to freeciv-proxy, which finally sends Freeciv socket requests to the Freeciv servers. Implemented in Python.
So it sounds like the bundled freeciv server has patches for Websocket communications.
But below that it mentioned freeciv-proxy which sounds like it proxies the websocket to standard freeciv communications.

Are BOTH required, or can I just use the proxy with the unpatched server?

Thanks for the clarification.
The compatible server is being built as part of freeciv-web build, including the patching step.

Re: Set up for Freeciv-web

Posted: Mon Aug 28, 2023 10:26 pm
by Corbeau
jgauthier wrote: Fri Aug 25, 2023 3:18 pm I played FreeCiv a long, long time ago. I 'd like to play it again. I was looking at Freeciv-web and I noticed its requirements:
If you want to play solo, the native client is trivial to install. Easier by orders of magnitude.

Re: Set up for Freeciv-web

Posted: Thu Aug 31, 2023 1:38 pm
by jgauthier
cazfi wrote: Sat Aug 26, 2023 1:47 pm The compatible server is being built as part of freeciv-web build, including the patching step.
Thanks! I just used the docker build (with customizations) and let it do its thing!

Re: Set up for Freeciv-web

Posted: Thu Aug 31, 2023 1:38 pm
by jgauthier
Corbeau wrote: Mon Aug 28, 2023 10:26 pm If you want to play solo, the native client is trivial to install. Easier by orders of magnitude.
Definitely want multiplayer! I was able to get this working with the docker build for the most part.

Re: Set up for Freeciv-web

Posted: Thu Aug 31, 2023 7:27 pm
by Elefant
The standard local freeciv can handle multiplayer as well. I think freeciv web just adds some hosting tools and a browser client.

Re: Set up for Freeciv-web

Posted: Thu Aug 31, 2023 10:36 pm
by Corbeau
I mean, Freeciv was made for multiplayer...