Integrate OnlyOffice

Hi everyone… I’m installing nextcloud on docker behind reverse proxy (jwilder/nginx-proxy).

I have NextCloud with https and the idea is to use virtual_host in the proxy since I want to have several nextcloud identified by the url.

I install the nc, onlyoffice and nginx containers, run the script called “set_configuration.sh” to integrate it, then try to open an office document, but just then a banner appears saying:

“The document could not be saved. Please check your connection settings or contact your administrator.
Clicking the “OK” button will prompt you to download the document”

and above another sign appears:
“Download error
Press “OK” to return to the list of documents”

Nextcloud versión: Nextcloud Hub II - 23.0.3

Please fill out the #support template you skipped when posting and include the logs it asks for. Thanks!

You can also search your error on Google and the forum. Possible solution:

you need to add the onlyoffice document servers url to the trusted sites on the nextcloud config.php.

Then only this setting worked for me →

sudo docker run --net onlyoffice -i -t -d -p 443:443 --restart=always
-v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data onlyoffice/documentserver \

Then I followed the onlyoffice tutorial found here → https://helpcenter.onlyoffice.com/server/docker/document/docker-installation.aspx

to get self-signed certs. I’m still trying to figure out how to get lets encrypt to work with the docker image. Let me know if you get any progress!

Hi @just

  'trusted_domains' => 
  array (
    0 => 'nextcloud.domain.cl',
    1 => 'proxy_nginx',
    2 => 'onlyoffice-document-server',
    3 => '172.20.1.5',
  ),

*** 172.20.1.5 is the ip for onlyoffice container
**** onlyoffice-document-server is the container name

add the last 2 lines, restart apache and reload the page, but the same message still appears

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 20.0.5): Nextcloud Hub II - 23.0.3
Operating system and version (eg, Ubuntu 20.04): Ubuntu 20.04.4 LTS
Apache or nginx version (eg, Apache 2.4.25): jwilder/nginx-proxy
PHP version (eg, 7.4): PHP 8.0.17 (container nextcloud)

The issue you are facing:

Is this the first time you’ve seen this error? (Y/N): Y

Steps to replicate it:

  1. I install the nc, onlyoffice and nginx containers
  2. run the script called “set_configuration.sh” to integrate it
  3. then try to open an office document

The output of your Nextcloud log in Admin > Logging:

“The document could not be saved. Please check your connection settings or contact your administrator.
Clicking the “OK” button will prompt you to download the document”

and above another sign appears:
“Download error
Press “OK” to return to the list of documents”

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'htaccess.RewriteBase' => '/',
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'apps_paths' => 
  array (
    0 => 
    array (
      'path' => '/var/www/html/apps',
      'url' => '/apps',
      'writable' => false,
    ),
    1 => 
    array (
      'path' => '/var/www/html/custom_apps',
      'url' => '/custom_apps',
      'writable' => true,
    ),
  ),
  'instanceid' => 'ocwhyk',
  'passwordsalt' => 'eYJJCrmoAfFaMPFhQg',
  'secret' => '4oBijgkZFtBNm3z3W07CkOtniKibA1RFqBUoi',
  'trusted_domains' => 
  array (
    0 => 'nextcloud.domain.cl',
    1 => 'proxy_nginx',
    2 => 'onlyoffice-document-server',
    3 => '172.20.1.5',
  ),
  'datadirectory' => '/var/www/html/data',
  'dbtype' => 'mysql',
  'version' => '23.0.3.2',
  'overwrite.cli.url' => 'http://nextcloud.domain.cl',
  'overwriteprotocol' => 'https',
  'dbname' => 'nextcloud',
  'dbhost' => 'db_nextcloud',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => 'XXXXXXXX',
  'installed' => true,
  'onlyoffice' => 
  array (
    'DocumentServerUrl' => '/ds-vpath/',
    'DocumentServerInternalUrl' => 'http://onlyoffice-document-server/',
    'StorageUrl' => 'http://proxy_nginx/',
  ),
);

The output of your Apache/nginx/system log in /var/log/____:

no error

PASTE HERE


Output errors in nextcloud.log in /var/www/ or as admin user in top right menu, filtering for errors. Use a pastebin service if necessary.

no error

some answer??