1. system conditions
Operating System: CentOS 7
NextCloud: 28.0.3
Onlyoffice: 8.0.1-31
NextCloud uses HTTP for SSL, and OnlyOffice uses Nginx for SSL
2. certificate
NextCloud uses Certbot,
OnlyOffice uses self signature
3. Current situation
NextCloud can be used normally and accessed through SSL. OnlyOffice has been installed and enabled in the app store. OnlyOffice has been deployed according to the official documentation and can also be accessed through SSL. The OnlyOffice interface can be opened normally and document editing can be uploaded.
NextCloud:
Onlyoffice:
4. issue
NextCloud displays
Error while downloading the document file to be converted when entering the connection information for OnlyOffice (Version 8.0.1.31)
By checking the log error of onlyOffice, the following content was found:
[2024-03-11T22:42:48.094] [ERROR] [localhost] [conv_check_814319493_docx] [userId] nodeJS - error downloadFile:url=https://172.168.1.101:5999/apps/onlyoffice/empty?doc=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhY3Rpb24iOiJlbXB0eSJ9.iVJuPavoLUTl_66tBK0dKg_mdzMcs-D55e-7LvlGmJg;attempt=3;code:null;connect:null Error: Error response: statusCode:404; headers:{“server”:“nginx”,“date”:“Mon, 11 Mar 2024 14:42:48 GMT”,“content-type”:“text/html; charset=utf-8”,“transfer-encoding”:“chunked”,“connection”:“keep-alive”,“vary”:“Accept-Encoding”,“content-security-policy”:“default-src ‘none’”,“x-content-type-options”:“nosniff”,“content-encoding”:“gzip”};
at Request.fResponse (/snapshot/server/Common/sources/utils.js)
at Request.emit (node:events:527:28)
at Request.onRequestResponse (/snapshot/server/Common/node_modules/request/request.js:1066:10)
at ClientRequest.emit (node:events:527:28)
at HTTPParser.parserOnIncomingClient (node:_http_client:631:27)
at HTTPParser.parserOnHeadersComplete (node:_http_common:128:17)
at TLSSocket.socketOnData (node:_http_client:494:22)
at TLSSocket.emit (node:events:527:28)
at addChunk (node:internal/streams/readable:315:12)
at readableAddChunk (node:internal/streams/readable:289:9)
at TLSSocket.Readable.push (node:internal/streams/readable:228:10)
at TLSWrap.onStreamRead (node:internal/stream_base_commons:190:23)
5. My profile
NextCloud:
<?php
$CONFIG = array (
'instanceid' => 'ocb03arsb182',
'passwordsalt' => 'VLkldjp1G0D3Sc69213dyEE1CCnh6z',
'secret' => '8HByL8XopwBtNfVgQ4TtDXo4RU0E8fUho71C7K/EoMDMl5yX',
'trusted_domains' =>
array (
0 => '*',
),
'datadirectory' => '/home/nextclouddata',
'dbtype' => 'mysql',
'version' => '28.0.3.2',
'overwrite.cli.url' => 'https://172.168.1.101',
'htaccess.RewriteBase' => '/',
'dbname' => 'nextcloud',
'dbhost' => 'localhost',
'dbport' => '',
'dbtableprefix' => 'oc_',
'dbuser' => 'nextcloud',
'dbpassword' => 'nextcloud',
'installed' => true,
'default_language' => 'zh_CN',
'memcache.local' => '\\OC\\Memcache\\Redis',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'redis' =>
array (
'host' => 'localhost',
'port' => 6379,
'timeout' => 0.0,
),
'maintenance_window_start' => 1,
'overwriteprotocol' => 'https',
'maintenance' => false,
'appstoreenabled' => true,
'appstoreurl' => 'https://www.orcy.net/ncapps/v2/',
'cors.allowed-domains' => 'https://172.168.1.101:5999',
'auth.bruteforce.protection.enabled' => false,
'app_install_overwrite' =>
array (
0 => 'richdocumentscode',
1 => 'richdocuments',
),
);
Onlyoffice:
[root@nextcloud nginx]# cat /etc/onlyoffice/documentserver/local.json
{
"services": {
"CoAuthoring": {
"sql": {
"dbHost": "localhost",
"dbName": "onlyoffice",
"dbUser": "onlyoffice",
"dbPass": "onlyoffice",
"type": "postgres",
"dbPort": "5432"
},
"token": {
"enable": {
"request": {
"inbox": true,
"outbox": true
},
"browser": true
},
"inbox": {
"header": "Authorization"
},
"outbox": {
"header": "Authorization"
}
},
"requestDefaults": {
"rejectUnauthorized": false
},
"secret": {
"inbox": {
"string": "2Q1wFfKBgRVl8AnZWQZrN7nQnZ1qSUps"
},
"outbox": {
"string": "2Q1wFfKBgRVl8AnZWQZrN7nQnZ1qSUps"
},
"session": {
"string": "2Q1wFfKBgRVl8AnZWQZrN7nQnZ1qSUps"
}
}
}
},
"queue": {
"type": "rabbitmq"
},
"rabbitmq": {
"url": "amqp://guest:guest@localhost"
},
"storage": {
"fs": {
"secretString": "VMwSryFp0SqXaJLRtLPe"
}
}
}
Finally, I hope that all experts can help solve this problem. It has been bothering me for over half a month now, thank you all!