Always attempting to connect using default port

The server has a proxy setup. Everything seems to be working fine. Server is listed too. Connecting to the game from the server list works without any issue. I say it’s working because the proxy/info.json, players.json, client and dynamic.json responds to 200 and throws the json information on the browser. In addition, accessing the domain directly ( redirects to “**myservercode**”.
One thing to note too is the server is not using the default 30120 port.

The only problem is, when trying to connect through the console and typing “connect”, it throws and error saying failed to connect when in fact, 30120 is not the server port. In addition, it should not read as because the port I am using is already aligned with the domain. So using connect (without the port) should be the same as connect IPaddress:port

Hope this makes sense.
Thank you

1 Like

Figured out that connect and connect are different. The unsecured request puts the port at the end for some reason.

Should I change proxy_pass http to proxy_pass https?

This actually depends on the scheme - host.example will complete to host.example:30120 (and lead to a HTTP request there), but http://host.example/ and https://host.example/ will be passed verbatim.

I’ve submitted a pull request to the documentation to clarify this.

Thank you so much for responding. To provide you with a more detailed information about this. I’ll write them all below.

I’d go first with CF settings.
I setup A record to the proxy server IP address.
In addition to this, I have also enabled SSL Origin Authenticated Origin Pulls and SSL mode to “Strict”.
Origin Certificates are installed on the proxy server (cert and priv). I can confirm that the ssl certs are working as I can directly visit on the browser. Curl returns 200.
No additional settings were made and caching is set to standard.

On the proxy server, I have followed all instructions provided online, specifically and
I can confirm that I was able to make this work as I am able to connect.
info.json, players.json, dynamic.json and client are accessible.

On the Fivem server side, server.cfg, I have this settings:

The issue:
1.) When connecting through the default server list, user can connect when clicking on the “Connect” button however:
2.) Sometime (reported by several players), the “Connect” button is greyed out saying that the server is offline. This happens while other people are inside the game including me.
3.) When connecting through the console F8, the syntax has to be connect User will be able to connect without any issue. Connecting without including the “https://” will throw an error stating "Unable to connect →

Error states 30120 when server is using 30122. I’m so confused because typing the domain directly on the browser works like a charm. It will ask you to open Fivem then it will connect you automatically.

I will keep checking the thread and GitHub. Hopefully I can find a fix.
Thanks again :smiley:

Hey, @BossKitz please check the issue at github and comment if the issue you are experiencing is the same.


1 Like