Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to connect to nextcloud office with collabora #3197

Closed
UltraBlackLinux opened this issue Sep 23, 2023 · 5 comments
Closed

Failed to connect to nextcloud office with collabora #3197

UltraBlackLinux opened this issue Sep 23, 2023 · 5 comments

Comments

@UltraBlackLinux
Copy link

UltraBlackLinux commented Sep 23, 2023

Describe the bug
About two days ago I first set up nextcloud, but I had to reinstall twice, and since that first attempt (on 27.0.7 afaik), collabora no longer worked ever again. When I open a libreoffice document all it does is load for a while and then complain about being unable to open nextcloud office.

To Reproduce

  1. Install the nextcloud community image (I haven't tried the AIO image since that's a PITA to set up and pretty much forces me to test on prod)
  2. Install Nextcloud office
  3. Install the built-in collabora server or spin up the official collabora docker image
  4. Check the settings: It can find the server
  5. Open a libreoffice document
  6. "Failed to open nextcloud office"

Expected behavior
It should open the document

Client details:

  • OS: Arch Linux
  • Browser Firefox
  • Version 117.01
  • Device: Desktop

Server details

Operating system: Arch Linux (don't question it 😉)
Web server: Apache
Database: Mariadb
PHP version: Built into the docker image, no idea
Nextcloud version: 27.0.7-27.1.1
Version of the richdocuments app 8.2.0
Version of Collabora Online 23.05.4.2.1

Logs

Nextcloud log (data/nextcloud.log)

if this is what I can also see in the admin console, this is probably not of any use. The admin console showed absolutely no info about te collabora problem. Those timeouts are 30 minutes old and probably unrelated
nextcloud.log

Browser log

console-export-2023-9-23_12-51-16.txt

Test dockerfile:
(untested, edited version of mine, should still be able to showcase the problem)
Install collabora into nextcloud:

docker exec -u 33 nextcloud php -d memory_limit=512M ./occ app:install richdocuments
docker exec -u 33 nextcloud php -d memory_limit=512M ./occ app:install richdocumentscode

try the built-in server and the docker container at nextcloud-collabora:9980

version: '3'

networks:
    nextcloud-db:
    nextcloud-collabora:
    
volumes:
    nextcloud:
    nextcloud-db:

services:
    nextcloud-db:
        image: docker.io/mariadb:latest
        container_name: nextcloud-db
        restart: always
        command: --transaction-isolation=READ-COMMITTED --log-bin=binlog --binlog-format=ROW
        volumes:
            - nextcloud-db:/var/lib/mysql
        networks:
            - nextcloud-db
        environment:
            - MYSQL_ROOT_PASSWORD=root
            - MYSQL_PASSWORD=nc
            - MYSQL_DATABASE=nc
            - MYSQL_USER=nc

    nextcloud-collabora:
        image: docker.io/collabora/code:23.05.4.2.1
        container_name: nextcloud-collabora
        restart: always
        networks:
            - nextcloud-collabora
        environment:
            - "extra_params=--o:ssl.enable=false"

    nextcloud:
        build: docker.io/nextcloud:27
        container_name: nextcloud
        restart: always
        networks:
            - nextcloud-db
            - nextcloud-collabora
        volumes:
            - nextcloud:/var/www/html
        ports:
            - 80:80
        environment:
            - MYSQL_PASSWORD=nc
            - MYSQL_DATABASE=nc
            - MYSQL_USER=nc
            - MYSQL_HOST=nextcloud-db
@UltraBlackLinux
Copy link
Author

UltraBlackLinux commented Oct 8, 2023

I have noticed a problem. There is one request that continuously receives 404s which seems to be responsible for opening the document edtor:
/custom_apps/richdocumentscode/proxy.php?req=/browser/0b27e85/cool.html?WOPISrc=https%3A%2F%2Fserver%2Fcloud%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F801_instanceid&title=%2Fgorgonzola.odp&lang=en&closebutton=1&revisionhistory=1

The problem is that /custom_apps/ is not the correct webroot. It should be /path/custom_apps/

@djzwerg
Copy link

djzwerg commented Oct 16, 2023

Did you see this issue?

@UltraBlackLinux
Copy link
Author

UltraBlackLinux commented Oct 16, 2023

No I haven't, thank you!

It does seem slightly different though. Nobody seems to be mentioning that path issue that I think I found

@seth586
Copy link

seth586 commented Nov 12, 2023

Paste the results from the following command:

php occ config:list richdocuments

If you are having 404 access errors it could be due to 'public_wopi_url' being miscoded

@UltraBlackLinux
Copy link
Author

Thanks for that hint, yeah the path was indeed incorrect. I also just found #3262, but even after following the steps, it's still using the old path, even though it shows the new path in the config. I tried both restarting nextcloud and applying the config. I'm gonna reply there since that's where something is actually happening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants