richdocumentscode
                                
                                
                                
                                    richdocumentscode copied to clipboard
                            
                            
                            
                        Blank page with Collabora in Nextcloud behind Apache proxy - Mixed content error
I have SNAP NC 19.0.3 installed with Collabora built in code server 4.2.8 and Collabora online 3.7.4. In NC settings it shows a tick and Collabora online server as reachable. If I configure and access NC as http://192.168.1.? it works ok and so does Collabora. However if I configure and access via an Apache Proxy on 192.168.1.12 (https>http) ie, https:// nextcloud.my.domain, NC works fine but opening a document gives me a white page. Noted that in NC settings it shows a tick and Collabora online server is still reachable.
Selecting the demo server works OK. Switching back to built in code server is the same fault again.
I have been doing some searching but can't find a solution. I am guessing it is either an https>http issue or the proxy but so far I am stumped. BTW, using Onlyoffice & Community Document Server works OK.
PS
On inspecting the Firefox console output it is showing mixed content errors:
Content Security Policy: The page's settings blocked the loading of a resource at http://nc.my.domian/extra-apps/richdocumentscode/proxy.php?status ("connect-src").
So how do I get the Collabora code server to work via https>http apache proxy or is it not possible with Nextcloud Snap?
Having spent some time on this issue I have come to the conclusion that Collabora internal code server is not a working option with Snap HTTP NextCloud behind an Apache Proxy server that terminates HTTPS given the mixed content error and the inability to edit Snap config files.
A pity but the best working option for now is to use OnlyOffice or a manual non Snap NC install and then go onto work out how to fix the mixed content error.
The proxy was a red hearing. A fresh standard non snap install of NC 20 with richdocument installed gives a working Collabora. Then adding a self signed SSL to Apache and adjusting the NC config for SSL gives a mixed content error when loading a doc and Collabora.
Is there anyway to get richdocument to reply using HTTPS as setup on NC rather than ignoring and using http?
I'm seeing this issue too. Did you ever find a solution that didn't involve using onlyoffice instead? If you did I'd be interested in knowing the solution.
Hello,
I am experiencing the same mixed content issue.
Content Security Policy: The page’s settings blocked the loading of a resource at http://cloud/apps/richdocumentscode/proxy.php?status (“connect-src”).
Blocked loading mixed active content “http://cloud/apps/richdocumentscode/proxy.php?req=/loleaflet/8979e63/loleaflet.html?WOPISrc=https%3A%2F%2Fcloud%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F24396_oc3wcorj7xgw&title=test.ods&lang=en&closebutton=1&revisionhistory=1”
If I attempt to reach these URLs over https there is a response and Collabora does attempt to load but there are simply more mixed content failures.
I have been unable to find any setting or config file where I can correct this.
If you choose to use the internal server (which I want because this is a setup for light use) It understandably does not give you any other configuration options. It should have all the info it needs. And it almost works where it not for a small oversight.
I did set overwrite protocol in the nextcould settings but that does not have any effect on it ether.
Also updated to NextCloud 21.0.1 but that made no difference.
I have  Collabora Online 4.0.4 installed with Collabora Online - Built-in CODE Server 6.4.705
Same here. I have a reverse-proxy in front of Nextcloud, that does the https encryption, and Nextcloud is on another machine (exposed with http). This setup works fine for all other Nextcloud apps.
When trying to open a document handled by Collabora, the browser tries to directly access the nextcloud server (with http) which is blocked (because of mixed content)
Nextcloud 21.0.2 with Collabora Online 4.1.1 and built-in CODE 6.4.806 (arm64 version)
Is there a solution to using Collabora with Nextcloud behind a reverse proxy yet?
I am experiencing the same issue. Just setup Nextcloud and Collabora in two docker instances. Nginx is running as https reverse proxy on a separate machine. No matter the configuration, I cannot get around the mixed content error message when trying to view a document in Nextcloud.
yeah this is a issue without support for nextclouds overwriteprotocol it is basically impossible to use this over a reverse proxy with https. I struggled with it for a few days now
Finally I found a solution here
Add
'overwriteprotocol' => 'https'to your config.php
Already have this in my config, so I'm still broken.
Already have this in my config, so I'm still broken.
With 'overwriteprotocol' => 'https' configured, try changing the server setting to "Use your own server" and check the box for "Disable certificate verification"

After hitting save, it defaults back to selecting the built-in CODE option (I think it detected the same server name), but after checking the box it worked for me with no error.

I have the same problem. I use Nginx as reverse proxy which does the HTTPS-termination and forwards traffic to Nextcloud using plain HTTP. None of the options in this thread worked for me. Also, Nextcloud is not running on the root path of my server but on a subpath called "nextcloud". I access my Nextcloud using https://my-server.tld/nextcloud, which works fine for everything except Collabora-Online.
My CPS message looks like this:
Content Security Policy: The page’s settings blocked the loading of a resource at http://my-server.tld/custom_apps/richdocumentscode/proxy.php?req=/browser/358ba77/cool.html?WOPISrc=https%3A%2F%2Fmy-server.tld%2Fnextcloud%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F...
It looks like not only the scheme is wrong (http instead of https) but also it is missing the correct root path, which is configured in config.php using 'overwritewebroot' => '/nextcloud'
This is still an issue in Nextcloud version 25.0.2. Has anyone found a solution yet?
I'm still on the latest 24 version and it stopped working for me.
I receive now the following error message:
Content Security Policy: The page’s settings blocked the loading of a resource at data: (“media-src”).
In my case, this solved the issue
@Megver83 Thanks a lot for posting this! That worked for me :)
hello, same problem for me to