Hello Everyone,
yesterday i decided to upgrade my server and improve some things on it to make it more reliable and secure.
what i have:
- debian 8.10 dedicated server
- nginx and docker running on root.
What i did:
- installed a nginx
- installed php7
- installed certbot to be able to use letsencrypt
- installed nextcloud
- configured nginx to work with my nextcloud installation (no problems as far as i can see)
- configured nextcloud and activated collabora online
- installed docker and made the collabora online server image running
â i used the following commandline
sudo docker run -t -d -p 127.0.0.1:9980:9980 -e 'domain=<mysubForNextcloud>\.<mywebsite>\.de' --restart always --cap-add MKNOD collabora/code
- created a vhost for collabora online which looks like this
server {
listen 443 ssl;
server_name < mysubForCollabora.<mywebsite>.de;
include /etc/nginx/snippets/letsencrypt.conf;
ssl on;
ssl_certificate /etc/letsencrypt/live/<mywebsite>.de/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/<mywebsite>.de/privkey.pem;
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:50m;
ssl_session_tickets off;
# static files
location ^~ /loleaflet {
proxy_pass https://localhost:9980;
proxy_set_header Host $http_host;
}
# WOPI discovery URL
location ^~ /hosting/discovery {
proxy_pass https://localhost:9980;
proxy_set_header Host $http_host;
}
# main websocket
location ~ ^/lool/(.*)/ws$ {
proxy_pass https://localhost:9980;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $http_host;
proxy_read_timeout 36000s;
}
# download, presentation and image upload
location ~ ^/lool {
proxy_pass https://localhost:9980;
proxy_set_header Host $http_host;
}
# Admin Console websocket
location ^~ /lool/adminws {
proxy_pass https://localhost:9980;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $http_host;
proxy_read_timeout 36000s;
}
}
i created a simlink for the subdomain file ..de.conf and created a simlink from the sites-activated folder to the sites-enabled folder
after this i restarted nginx
- when i now, wanna create a document or open one, i get the following error in nextcloud
GuzzleHttp\Exception\ServerException: Server error response [url] https://<mysubForCollabora>.<mywebsite>.de/hosting/discovery [status code] 502 [reason phrase] Bad Gateway
Note: the domain and sub domains have a valid lets encrypt certificate.
Could someone help me on this?