Docker + Reverse proxy (nginx) + NetxCloud + OnlyOffice + HTTPS

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face: is for home/non-enterprise users. If you’re running a business, paid support can be accessed via 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:


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


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 (23.0.3) (image: nextcloud)
Operating system and version (eg, Ubuntu 20.04): Ubuntu 20.04.4 LTS (Host)
Apache or nginx version (eg, Apache 2.4.25): nginx version: nginx/1.21.6 (image: “wilder/nginx-proxy”)
PHP version (eg, 7.4): PHP 8.0.17 (cli) (dentro del contenedor de nextcloud)

The issue you are facing:

Levanto el contenedor de NextCloud y el contenedor de BD sin problemas, entro a la url y se instala, pero por defecto no funcionan los archivos office (.docx, .xlsx, etc).
Para poder abrirlos estoy intentando activar la aplicación “Community Document Server” y luego “ONLYOFFICE”. Después de hacer esto en la opción de “Configuracion → ONLYOFFICE → url onlyoffice docs” aparece por defecto:

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

Steps to replicate it:

The output of your Nextcloud log in Admin > Logging:

Error	onlyoffice	OCP\Http\Client\LocalServerException: Host violates local access rules

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

{"reqId":"UQE9FcZnx4FBDmzAqCb0","level":2,"time":"2022-03-29T18:06:27+00:00","remoteAddr":"","user":"usuario","app":"no app in context","method":"PUT","url":"/apps/onlyoffice/ajax/settings/address","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.82 Safari/537.36","version":"","id":"62434aa3af7fe"}

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

$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' => 'ocy6kalhp2um',
  'passwordsalt' => 'MgFiregF0q+e/VN6ScC2Vii/XP/T+z',
  'secret' => 'cSe74RP4JfOMebECexcHa0WW+R+vt7o4fGJZwfGVY0XJRnXN',
  'trusted_domains' => 
  array (
    0 => '',
  'datadirectory' => '/var/www/html/data',
  'dbtype' => 'mysql',
  'version' => '',
  'overwrite.cli.url' => '',
  'dbname' => 'nextcloud',
  'dbhost' => 'db_nextcloud_lider',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => 'Lider.2022',
  'installed' => true,