Request to /templates slow to load after installing collabora

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:

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • 31.0.2
  • Operating system and version (e.g., Ubuntu 24.04):
    • Ubuntu 24.04
  • Web server and version (e.g, Apache 2.4.25):
    • `Apache 2.4.62
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    • traefik v3.3
  • PHP version (e.g, 8.3):
    • 8.3.19
  • Collabora version:
    • 24.04.13.2.1
  • Is this the first time you’ve seen this error? (Yes / No):
    • Yes
  • When did this problem seem to first start?
    • When I configured collabora
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • docker image: nextcloud:31.0.2-apache with separate redis, mariadb, and traefik
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • no

Summary of the issue you are facing:

I set up nextcloud and it’s working great, nice and fast all around. I want to use collabora, so I set up a collabora server and that works well too. The only issue I have is that it takes a long time for new documents to be made.

Specifically, when I click New and choose any of the files that have templates as options, the request to /ocs/v2.php/apps/files/api/v1/templates takes 30s or more to return, but it returns with an HTTP 200. This request provides the info for the templates in the dialog window, so I need to wait for this each time I want to make a new document, which is very annoying.

If I change NC to use the built in CODE server this goes away, and that request finishes in a second or so.

My challenge is, I can’t see any errors in the logs, so I really don’t know how to go about debugging this. Please help?

Steps to replicate it (hint: details matter!):

  1. Install nextcloud
  2. Install collabora
  3. Configure nextcloud to use collabora

Log entries

None relating to this, but I’m happy to share anyway if needed. It’s likely I’m missing something

Nextcloud

The only error that shows in my logs is

{"reqId":"HFmOd771rpeBWuuTmd3g","level":3,"time":"2025-04-03T05:47:44+00:00","remoteAddr":"10.10.11.2","user":"admin","app":"jsresourceloader","method":"GET","url":"/index.php/apps/files/","message":"Could not find resource text/js/.js to load","userAgent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.3.1 Safari/605.1.15","version":"31.0.2.1","data":{"app":"jsresourceloader"},"id":"67ee21af121fa"}

Web Browser

image

Web server / Reverse Proxy

The output of your Apache/nginx/system log in /var/log/____:
NC forwards these to stderr in this container, and I don’t see the same error as above here

Configuration

Nextcloud

The output of occ config:list system or similar is best, but, if not possible, the contents of your config.php file from /path/to/nextcloud is fine (make sure to remove any identifiable information!):

{
    "system": {
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "***"
        ],
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "maintenance_window_start": 1,
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "31.0.2.1",
        "overwrite.cli.url": "http:\/\/localhost",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "overwriteprotocol": "https",
        "loglevel": 2,
        "maintenance": false,
        "theme": "",
        "templatedirectory": "\/var\/www\/html\/config\/templates\/",
        "oidc_login_provider_url": "***",
        "oidc_login_client_id": "nextcloud",
        "oidc_login_client_secret": "***",
        "oidc_login_disable_registration": false,
        "app_install_overwrite": [
            "extract"
        ]
    }
}

Apps

The output of occ app:list (if possible).

Enabled:
  - activity: 4.0.0
  - app_api: 5.0.2
  - bruteforcesettings: 4.0.0
  - calendar: 5.2.0
  - calendar_resource_management: 0.9.0
  - circles: 31.0.0
  - cloud_federation_api: 1.14.0
  - comments: 1.21.0
  - contacts: 7.0.4
  - contactsinteraction: 1.12.0
  - dashboard: 7.11.0
  - dav: 1.33.0
  - deck: 1.15.0
  - federatedfilesharing: 1.21.0
  - federation: 1.21.0
  - files: 2.3.1
  - files_downloadlimit: 4.0.0
  - files_fulltextsearch: 31.0.0
  - files_mindmap: 0.0.33
  - files_pdfviewer: 4.0.0
  - files_reminders: 1.4.0
  - files_sharing: 1.23.1
  - files_trashbin: 1.21.0
  - files_versions: 1.24.0
  - firstrunwizard: 4.0.0
  - fulltextsearch: 31.0.0
  - groupfolders: 19.0.4
  - htmlviewer: 31.0.0
  - logreader: 4.0.0
  - lookup_server_connector: 1.19.0
  - mail: 4.3.3
  - metadata: 0.22.0
  - nextcloud_announcements: 3.0.0
  - notifications: 4.0.0
  - oauth2: 1.19.1
  - oidc_login: 3.2.2
  - password_policy: 3.0.0
  - previewgenerator: 5.8.0
  - privacy: 3.0.0
  - profile: 1.0.0
  - provisioning_api: 1.21.0
  - recommendations: 4.0.0
  - related_resources: 2.0.0
  - richdocuments: 8.6.3
  - richdocumentscode: 24.4.1302
  - serverinfo: 3.0.0
  - settings: 1.14.0
  - sharebymail: 1.21.0
  - support: 3.0.0
  - survey_client: 3.0.0
  - systemtags: 1.21.1
  - text: 5.0.0
  - theming: 2.6.1
  - twofactor_backupcodes: 1.20.0
  - updatenotification: 1.21.0
  - user_status: 1.11.0
  - viewer: 4.0.0
  - webhook_listeners: 1.2.0
  - workflowengine: 2.13.0
Disabled:
  - admin_audit: 1.21.0
  - analytics: 5.3.0 (installed 5.3.0)
  - appointments: 2.4.3 (installed 2.4.3)
  - drawio: 3.0.4 (installed 3.0.4)
  - encryption: 2.19.0
  - files_external: 1.23.0
  - integration_excalidraw: 2.4.0 (installed 2.4.0)
  - integration_mattermost: 2.1.0 (installed 2.1.0)
  - notes: 4.11.0
  - photos: 4.0.0-dev.1 (installed 4.0.0-dev.1)
  - spreed: 21.0.1 (installed 21.0.0)
  - suspicious_login: 9.0.1
  - tables: 0.9.0 (installed 0.9.0)
  - thesearchpage: 1.2.10 (installed 1.2.10)
  - twofactor_nextcloud_notification: 5.0.0
  - twofactor_totp: 13.0.0-dev.0
  - user_ldap: 1.22.0
  - weather_status: 1.11.0 (installed 1.11.0)
  - whiteboard: 1.0.5 (installed 1.0.5)