Token problem when connecting nextcloud 27.1 to document server

I’ve deployed the nextcloud docker container and onlyoffice/documentserver.
one displays
Mon Sep 18 10:53:27 CEST 2023
when the other one displays:
Mon Sep 18 08:53:27 AM UTC 2023

As a result, it seems that token generation is not possible.
How can I align the 2 schedules knowing that the 2 containers are on the same docker network?

My docker-compose.yml

version: '3.1'

services:

  nextcloud_onlyoffice:
    container_name: nextcloud_onlyoffice
    image: onlyoffice/documentserver
    restart: always
    volumes:
      - /volume1/docker/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data
      - /volume1/docker/onlyoffice/DocumentServer/log:/var/log/onlyoffice
    ports:
      - 4444:80
    networks:
      nextcloud:

  nextcloud:
    image: ghcr.io/linuxserver/nextcloud
    container_name: nextcloud
    depends_on:
      - nextcloud_db
      - nextcloud_redis
      - nextcloud_onlyoffice
#      - nextcloud_collabora
    links:
      - nextcloud_db:nextcloud_db
      - nextcloud_redis:nextcloud_redis
      - nextcloud_onlyoffice:nextcloud_onlyoffice
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Paris
    volumes:
      - /volume1/docker/nextcloud/root/config:/config
      - /volume1/docker/nextcloud/root/data:/data
    ports:
      - 4443:443
    restart: unless-stopped
    networks:
      nextcloud:

networks:
  nextcloud:

Thanks

Hello @alexb81
To be honest, I’m not sure that I understand the issue right. What exactly have you faced?
one displays
Mon Sep 18 10:53:27 CEST 2023
when the other one displays:
Mon Sep 18 08:53:27 AM UTC 2023
These times are the same, but different time zones. It shouldn’t affect the situation.
Please go to connector app and click Save button, please make a screenshot of the result (entire page). After that please collect Document server logs (you have mapped they here: /volume1/docker/onlyoffice/DocumentServer/log) and provide us with them.
Additionally, please let us know the exact version of the connector app.

Thanks,
Here are the screenshots

root@nasfamilleb:/volume1/docker/onlyoffice/DocumentServer/log/documentserver# vi nginx.error.log
2023/09/20 02:04:36 [error] 7199#7199: *1 connect() failed (111: Unknown error) while connecting to upstream, client: 192.168.0.3, server: , request: "GET /example/ HTTP/1.0", upstream: "http://127.0.0.1:3000/", host: "onlyoffice.backup.familleblav.ovh", referrer: "https://onlyoffice.backup.familleblav.ovh/welcome/"
2023/09/20 02:04:36 [error] 7199#7199: *1 connect() failed (111: Unknown error) while connecting to upstream, client: 192.168.0.3, server: , request: "GET /example/ HTTP/1.0", upstream: "http://127.0.0.1:3000/", host: "onlyoffice.backup.familleblav.ovh", referrer: "https://onlyoffice.backup.familleblav.ovh/welcome/"
2023/09/20 02:04:42 [error] 7199#7199: *4 no live upstreams while connecting to upstream, client: 192.168.0.3, server: , request: "GET /example/ HTTP/1.0", upstream: "http://example/", host: "onlyoffice.backup.familleblav.ovh", referrer: "https://onlyoffice.backup.familleblav.ovh/welcome/"
root@nasfamilleb:/volume1/docker/onlyoffice/DocumentServer/log/documentserver# cat docservice/out.log
[2023-09-20T01:43:39.319] [WARN] [localhost] [docId] [userId] nodeJS - Express server starting...
[2023-09-20T01:43:39.327] [WARN] [localhost] [docId] [userId] nodeJS - Failed to subscribe to plugin folder updates. When changing the list of plugins, you must restart the server. https://nodejs.org/docs/latest/api/fs.html#fs_availability
[2023-09-20T01:43:40.618] [WARN] [localhost] [docId] [userId] nodeJS - Express server listening on port 8000 in production-linux mode. Version: 7.4.1. Build: 36
[2023-09-20T01:44:47.141] [WARN] [localhost] [docId] [userId] nodeJS - Express server starting...
[2023-09-20T01:44:47.147] [WARN] [localhost] [docId] [userId] nodeJS - Failed to subscribe to plugin folder updates. When changing the list of plugins, you must restart the server. https://nodejs.org/docs/latest/api/fs.html#fs_availability
[2023-09-20T01:44:47.338] [WARN] [localhost] [docId] [userId] nodeJS - Express server listening on port 8000 in production-linux mode. Version: 7.4.1. Build: 36

root@nasfamilleb:/volume1/docker/onlyoffice/DocumentServer/log/documentserver# cat converter/out.log
[2023-09-20T01:43:36.415] [WARN] [localhost] [docId] [userId] nodeJS - update cluster with 1 workers
[2023-09-20T01:43:36.432] [WARN] [localhost] [docId] [userId] nodeJS - worker 644 started.
[2023-09-20T01:43:36.437] [WARN] [localhost] [docId] [userId] nodeJS - update cluster with 1 workers
[2023-09-20T01:44:47.694] [WARN] [localhost] [docId] [userId] nodeJS - update cluster with 1 workers
[2023-09-20T01:44:47.712] [WARN] [localhost] [docId] [userId] nodeJS - worker 800 started.
[2023-09-20T01:44:47.716] [WARN] [localhost] [docId] [userId] nodeJS - update cluster with 1 workers

hoping to have been complete

Hello @alexb81
I see empty JWT secret on your screenshot. Did you disable JWT on the Document server side too? Please check out this setting in /etc/onlyoffice/documentserver/local.json file.

Hello,

I fond the file in the container but not the string. I have:

{
  "services": {
    "CoAuthoring": {
      "sql": {
        "type": "postgres",
        "dbHost": "localhost",
        "dbPort": "5432",
        "dbName": "onlyoffice",
        "dbUser": "onlyoffice",
        "dbPass": "onlyoffice"
      },
      "token": {
        "enable": {
          "request": {
            "inbox": true,
            "outbox": true
          },
          "browser": true
        },
        "inbox": {
          "header": "Authorization",
          "inBody": false
        },
        "outbox": {
          "header": "Authorization",
          "inBody": false
        }
      },
      "secret": {
        "inbox": {
          "string": "zzzzzzzz"
        },
        "outbox": {
          "string": "zzzzzzzz"
        },
        "session": {
          "string": "zzzzzzzz"
        }
      }
    }
  },
  "rabbitmq": {
    "url": "amqp://guest:guest@localhost"
  },
  "storage": {
    "fs": {
      "secretString": "xxxxxxxxxx"
    }
  }
}

If I use zzzzzzzz:

If I use xxxxxxxxxx

Thanks

Hello @alexb81

Please execute command bash /usr/bin/documentserver-update-securelink.sh from inside the Docker container with Document Server and try connecting again specifying the value that you’ve mentioned here in Secret key field of the connector app:

The result

Did I forget an option in the docker-compose?

Is your environment located in local network? I mean whether Document Server and Nextcloud can be accessed externally or not.

Hello,

The 2 containers are on the same docker network. Access to them is via an external url, and to my knowledge I don’t remember adding the external domain name to the server document.

Please run a test: go to the Document Server address via browser, you will open Welcome Page, on that page you will see an instruction on how to enable integrated test example, enable it and then please try creating a document to see if editors are working.

If you face any warning/error, make screenshot of it to share.

After that, navigate to /healthcheck page and share the output of this page.

Hello,

No error when creating a Word document with this method.
The result of the requested page

image

Thank you for the feedback.

Do you have Advanced server settings section opened on the connector app page? If you do, please try closing it and connecting again.

Just as a reminder, for the Secret key value you need to specify the value from local.json that in this example marked as <secret>:

      "secret": {
        "inbox": {
          "string": "<secret>"
        },
        "outbox": {
          "string": "<secret>"
        },
        "session": {
          "string": "<secret>"

Hello and sorry,

I didn’t see your message. I just tested it by closing the advanced configuration options in nextcloud and it works.

Thanks

1 Like