Trying to connect collabora to nextcloud

Hi, I’m running nextcloud and collabora on my home server using docker compose, which I connect to via tailscale. From my client computer I can connect to collabora using the tailscale url http://mytailscaleurl:9980 but when I try to use it in the nextcloud office configuration panel it can’t connect (I guess because the url isn’t accessible from within the container. When I try to use collabora:9980, using the container name, it briefly connects with

Collabora Online server is reachable.

Collabora Online Development Edition 25.04.7.1 e808afa229

URL used by the browser: http://collabora:9980
Nextcloud URL used by Collabora: http://mytailscaleurl:8085 (Determined from the browser URL)

but after a few seconds shows

Your browser has been unable to connect to the Collabora server: http://collabora:9980

This URL is determined on the Collabora server either from the configured URL or the server_name parameter in coolwsd.xml.

My docker compose file is as follows:

services:
  db:
    image: mariadb:latest
    container_name: nextcloud-db
    restart: unless-stopped
    command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
    environment:
      MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
      MYSQL_DATABASE: nextcloud
      MYSQL_USER: nextcloud
      MYSQL_PASSWORD: ${MYSQL_PASSWORD}
    volumes:
      - /srv/nextcloud/db-data:/var/lib/mysql
    networks:
      - nextcloud-net

  redis:
    image: redis:7
    container_name: nextcloud-redis
    restart: unless-stopped
    networks:
      - nextcloud-net

  app:
    image: nextcloud:latest
    container_name: nextcloud-app
    ports:
      - "8085:80"  # Change if needed
    restart: unless-stopped
    environment:
      MYSQL_PASSWORD: ${MYSQL_PASSWORD}
      MYSQL_DATABASE: nextcloud
      MYSQL_USER: nextcloud
      MYSQL_HOST: db
      REDIS_HOST: redis
    depends_on:
      - db
      - redis
    volumes:
      - /srv/nextcloud/data:/var/www/html
    # Optional: enable Nextcloud cron job
    entrypoint: /entrypoint.sh apache2-foreground
    networks:
      - nextcloud-net
      
  collabora:
    image: collabora/code:latest
    container_name: collabora
    restart: unless-stopped
    environment:
      - domain=my\.tailscale\.url\(:8085)?  # Replace with your Nextcloud domain or localhost for testing
      - username=admin     # Optional admin user
      - password=mycustompassword    # Optional admin password
      - extra_params=--o:ssl.enable=false
      - aliasgroup1=http://mytailscaleurl:9980

    ports:
      - "9980:9980"
    networks:
      - nextcloud-net

networks:
  nextcloud-net:
    driver: bridge

Any ideas on how to get them to connect?

I’m sorry no idea about tailscale specifics but you find details in Collabora integration guide
I assume the problem as you analysed already - likely some connections are not possible e.g.

start checking connectivity using curl or wget as described in the above guide. additionally you configure

which is CODE URL - aliasgroups is supposed to hold Nextcloud URL..

as 3rd topic I see http:// URL everywhere. WOPI protocol requires TLS - maybe there is another problem.

There are few topics related to tailscale - look if you find useful hints especially Local access for Collabora is focused on CODE, maybe AiO guide is helpful as well Tailscale (and Caddy as a sidecar) Reverse Proxy · nextcloud/all-in-one · Discussion #5439 · GitHub