Switching your ONLYOFFICE DocSpace to HTTPS

If you installed ONLYOFFICE DocSpace using Docker, you can switch the already installed DocSpace portal to HTTPS manually using the letsencrypt.org or own certificate and the /app/onlyoffice/config/docspace-ssl-setup file.

When switching to HTTPS, port 443 must be available.

If you want to switch your DocSpace to HTTPS during the installation from scratch or in cases when you use the DEB/RPM or Windows version, the corresponding instructions can be found in the Installation section.

Using the letsencrypt certificate

If you want to switch to HTTPS already installed DocSpace using the letsencrypt certificate, launch switching to HTTPS manually from the /app/onlyoffice/config/docspace-ssl-setup file:

bash /app/onlyoffice/config/docspace-ssl-setup user@example.com yourdomain.com

Where:

  • user@example.com is the email used for registration and recovery contact. Use comma to register multiple emails, for example: u1@example.com,u2@example.com.
  • yourdomain.com is the address of the domain where your ONLYOFFICE DocSpace portal is installed. Use comma to register multiple domains, for example: yourdomain1.com,yourdomain2.com.

The script will automatically create and install the letsencrypt.org CA-signed certificate to your server and restart the NGINX service for the changes to take effect.

Now your portal should be available via the https:// address.

Using own certificates

If you want to switch to HTTPS already installed DocSpace using your own certificates, launch switching to HTTPS manually from the /app/onlyoffice/config/docspace-ssl-setup file:

bash /app/onlyoffice/config/docspace-ssl-setup -f yourdomain.com /app/onlyoffice/fullchain.pem /app/onlyoffice/privkey.pem

Where:

  • yourdomain.com is the address of the domain where your ONLYOFFICE DocSpace portal is installed. Use comma to register multiple domains, for example: yourdomain1.com,yourdomain2.com.
  • /app/onlyoffice/fullchain.pem is the path to the certificate file for the domain.
  • /app/onlyoffice/privkey.pem is the path to the private key file for the certificate.
A self-signed certificate must have a full chain to work correctly.

Now your portal should be available via the https:// address.

Host ONLYOFFICE DocSpace on your own server or use it in the cloud

Article with the tag:
Browse all tags