Rocket.chat.electron: Windows app "No valid server found at the URL"

Created on 5 Oct 2020  路  21Comments  路  Source: RocketChat/Rocket.Chat.Electron

My Setup

  • Operating System: MS Windows 10 Pro
  • App Version: 3.0.2
  • Installation type: exe

  • [X] I have tested with the latest version
  • [X] I can simulate the issue easily

Description

Capture

Current Behavior


I can acces to my server usinf Mozuilla Firefox, chrome or edge, I also access from the android app
But after having done an update from 2.7 to 3.0.2, Now the application doesn't find my server.
My certificate is a real certificate (not a self signed)
Moreover, the new install erase the json file

Expected Behavior

After the update, the application should refind the json file and reconnect to the server

Most helpful comment

Thank you TheWrongGuy
I did it and it WORKS !!

All 21 comments

I can confirm this using the MacOS client. The issue, first occured with 3.0, still exists in 3.0.2 that "no valid server found at url" shows up. Manually pre-configuring a servers.json works.

Thank you TheWrongGuy
I did it and it WORKS !!

I can confirm this using the MacOS client. The issue, first occured with 3.0, still exists in 3.0.2 that "no valid server found at url" shows up. Manually pre-configuring a servers.json works.

I haven't been able to get any of the 3.X versions to work on Mac despite added servers.json file etc.

Creating a servers.json in 'C:\Program Files\Rocket.Chat\resources\' works on Windows.

Unable to get the MacOS client working.

I can confirm this using the MacOS client. The issue, first occured with 3.0, still exists in 3.0.2 that "no valid server found at url" shows up. Manually pre-configuring a servers.json works.

What are contents of servers.json file ?

Issue still persists with 3.0.2 on Windows. Now even a manually added servers.json file doesn't fix the issue

Issue still persists with 3.0.2 on Windows. Now even a manually added servers.json file doesn't fix the issue

Sure ?
If you add the file servers.json [text file] in C:\Program Files\Rocket.Chat\resources directory
with content :
{
"Open Rocket Chat": "PUT HERE YOUR URL"
}

I can confirm this using the MacOS client. The issue, first occured with 3.0, still exists in 3.0.2 that "no valid server found at url" shows up. Manually pre-configuring a servers.json works.

What are contents of servers.json file ?

{
"Open Rocket Chat": "PUT YOUR URL HERE"
}

I got it working like this:
Added the servers.json to ~\Users\\AppData\Roaming\Rocket.Chat\ and then clicked on "Window" and selected my server

Trailing Space, Removing /home, adding servers.json... Nothing Works

Same with Mac OS Mojave, issue still persist with version 3.0.2. Did they just released it without testing ????

This is not just a Mac issue. I'm experiencing it in a private domain with mixed clients.
Hacking a solution with servers.json is not reliable and breaks when a user resets the app from the help menu so that is a bit of a one off.

My SSL and domain configuration sounds similar to the one @HermanCattaneo describes in issue 1781.
https://github.com/RocketChat/Rocket.Chat.Electron/issues/1787#issuecomment-704785540

My network and domain are private, that is not internet connected/dependent.
The private domain has an internal Certificate Authority that signs all "domain.local" certificates.
This private root certificate is trusted by all domain machines through the various operating systems' trust libraries.

My RocketChat Server uses an SSL certificate signed by this private Certificate Authority.

Everything has been working great for months.

My desktops' electron based RocketChat clients 'break' upon upgrading the desktop client to 3.0.0.
Downgrading to the latest 2.x electron client eliminates the problem immediately.
No other changes have been made to the working server/client/SSL-PKI environment.

Again, the private root certificate is trusted in applicable operating system certificate stores.
HTTPS access using Chromium browsers works regardless of the installed electron clients.

@tassoevan I suspect the 3.X Electron client does not support our private SSL configuration.

Were changes made to the SSL libraries in 3.X of the electron?
Does Electron 3.X use the system's trust root store?
Does the Electron 3.X client perform some sort of new URL/Server validation before storing the server information in the server list?

Workaround for macOS

  1. Add your rocket chat server url that has worked before
    (e.g. https://<yourDomain>/chat or https://chat.<yourDomain>)
  2. Fully close Rocket Chat Desktop App
  3. Go to /Users/<YourUsername>/Library/Application Support/Rocket.Chat
  4. Open config.json in an editor of your choice
  5. Search for "servers": [ { ... } ]
  6. Find "url": "https://<yourDomain>" without the /chat
  7. Replace with "url": "https://<yourDomain>/chat"
  8. Re-open Rocket.Chat Desktop App again and select your server
  9. You should see the login screen of your Rocket.Chat instance now - login as normal

Sample config before (only servers section):

"servers": [
        {
            "url": "https://<yourDomain>/",
            "title": "https://<yourDomain>/"
        }
    ]

Sample config afterwards (only servers section):

"servers": [
        {
            "url": "https://<yourDomain>/chat",
            "title": "Rocket.Chat - https://<yourDomain>/chat"
        }
    ]

@johanneshiry
Desktop client 3.0.3 solved the issue, please check: #1787

@tassoevan I think you can close this one too.

@HermanCattaneo I came from #1787 - didn't worked for me (macOS) and my colleague (Windows 10) with current Rocket.Chat Desktop Version 3.0.3 (and current rocket chat server version - I upgraded today bc of the issue) - it still cuts subfolders from the url. With the workarounds for Windows and macOS above we got it working.

Hence I would opt for keeping this one open as it _seems_ not fixed yet.

@johanneshiry sry no experience with subfolders and didn't see that you already tried the Desktop Client 3.0.3

I think it was an url validation problem that got fixet in Desktop Client 3.0.3, see this pull request: #1776

I downloaded it from here, not from the App Store (maybe thats a difference):
https://github.com/RocketChat/Rocket.Chat.Electron/releases/tag/3.0.3

Desktop Client 3.0.3 on macOS Catalina 10.15.6 from .dmg file
Server 3.7.1 in docker
my url is https://yourdomain.tdl/ not https://yourdomain.tdl/subfolder
Certificate is signed by own CA, that is set as trusted CA system wide

I hope this helps if not i'am sure @tassoevan can use this informations about your setup, so post it please

I'am just an enthusiastic user not developer, so that's all help / hint I can give.

no worries just wanted to prevent closing an obviously not solved issue with subfolders - we don't have a chance to install it using a subdomain in our case - here are my environment stats:

Desktop Client 3.0.0 on macOS Catalina 10.15.7 installed using homebrew
Windows Client also doesn't work
Server is 3.7.1 manual (non-docker) installation
Url is https://yourdomain.tdl/subfolder
Certificate is signed by Let'sEncrypt

Thanks for pointing me to #1776 - after checking the discussion in the PR it looks like they are aware of this and it's still an issue in 3.0.3 -> #1796

Hence the actual correct issue would be #1796 and I'm fine with closing this one then to avoid duplicates

@GELVE I think this was fixed in 3.0.3 or 3.0.4
I've tested 3.0.4 in my environment and the issue is resolved for my case.

I still facing the same issue, i even tried to test on 3.0.3 or 3.0.4 versions on my ubuntu 20.04 machine

I have the same issue using the Mac app.

I'm running RocketChat (0.62.1) on sloppy.io: https://tempnk-rocketchat.sloppy.zone and an getting this error using both Mac app 3.0.3 and 3.0.7

I've tried URLs including with a trailing /, and also including port 3000

Can anyone guide me?

I have the same issue using the Mac app.

I'm running RocketChat (0.62.1) on sloppy.io: https://tempnk-rocketchat.sloppy.zone and an getting this error using both Mac app 3.0.3 and 3.0.7

I've tried URLs including with a trailing /, and also including port 3000

Can anyone guide me?

your RocketChat server version should be 2 and above for the desktop version to work.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

agentirons picture agentirons  路  4Comments

wrwrwrr picture wrwrwrr  路  4Comments

tendo256 picture tendo256  路  4Comments

Sugaroverdose picture Sugaroverdose  路  3Comments

dryabchenko picture dryabchenko  路  5Comments