It’s working fine with IP but I have problem when change the dns setting and config host file from my local trying to access to domain it wont work and got 504 Gateway Time-out
Hello,
Please clarify, is this domain name that you provided resolved normally on the server and in Docker container?
You can check this by running nslookup onlyoffice.amaracapital.com
command on the host and in some container (for example, login container). Send us the output.
Also, send us the output of this command: curl --location http://onlyoffice.amaracapital.com/api/2.0/capabilities
(from the container)
Hi,
I’m facing the exact same problem.
Ping from the host returns the local IP of the server. Ping from containers returns the public IP associated to the DNS entry, I think that’s the problem.
Also running the curl command with the DNS hostname from containers returns:
curl: (7) Failed to connect to docs2.****.eu port 80: Connection refused
Running the curl command with the local IP:
{"response":{"ldapEnabled":false,"providers":[],"ssoLabel":"","oauthEnabled":true,"ssoUrl":""},"count":1,"links":[{"href":"http://192.168.222.56/api/2.0/capabilities","action":"GET"}],"status":0,"statusCode":200}
Any help is appreciated.
Thanks!
Hi,
It can be seen that the host resolves the domain name to the local IP and the portal is accessible, but in the container it resolves the domain name to the external IP, which is not accessible.
Docker uses Google DNS 8.8.8.8 by default for name resolution.
If the server cannot be accessed via external IP, DNS must return the internal IP. You need to change the DNS server for Docker
Changed to my local DNS servers on /etc/docker/daemon.json, restarted and solved. Thanks!
Now I’m facing that error when opening a document:
Mixed Content: The page at 'https://docs2.****.eu/doceditor/?fileId=4' was loaded over HTTPS, but requested an insecure frame 'http://docs2.******.eu/ds-vpath/8.0.1-31/web-apps/apps/spreadsheeteditor/main/index.html?_dc=8.0.1-31&lang=es&customer=ONLYOFFICE&headerlogo=https%3A%2F%2Fdocs2.******.eu%2F%2Fdoceditor%2Fstatic%2Fimages%2Flogo%2Fdocseditor.svg%3Fhash%3D99cf35c166a769f9a1a5&headerlogodark=https%3A%2F%2Fdocs2.****.eu%2F%2Fdoceditor%2Fstatic%2Fimages%2Flogo%2Fdocseditor.svg%3Fhash%3D99cf35c166a769f9a1a5&frameEditorId=docspace_editor&isForm=false&parentOrigin=https://docs2.******.eu&uitheme=default-light&fileType=xlsx'. This request has been blocked; the content must be served over HTTPS.
Switched to HTTPS the whole installation and same behaviour. Integration settings looks like this:
Any idea?
Thanks
Finally I tried to take it out from any reverse proxy and it’s working nice. When it’s proxied I’m experiencing the same behaviour as I previously stated on that post, last message speaking with @Nikolas :
If I access DocSpace from my local network with my local DNS pointing to the nginx reverse proxy everything works fine. Document editor opens extremely fast and all works wonders. But if I try to do so on another local network (so external connection) Document editor hangs on this state for like 30-120s (or more) and (normally) finally loads the Document:
Nginx config:
proxy_set_header X-Forwarded-Proto $forward_scheme;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $host;
server_tokens off;
ssl_verify_client off;
add_header X-Content-Type-Options nosniff;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
proxy_set_header Connection $http_upgrade;
root /usr/share/nginx/html;