[GH-ISSUE #232] Enabling HTTPS access Document Server on Ununtu #128

Closed
opened 2026-02-26 09:36:44 +03:00 by kerem · 6 comments
Owner

Originally created by @Sys-Admin889 on GitHub (Mar 14, 2020).
Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/232

Hello everyone,

  • I'm trying to install ONLYOFFICE Document Server and running it using
    HTTPS as the following instructions .

  • I need to know how to configure parameters as described bellow?
    Please refer the docker run command options for the --env-file flag where you can specify all
    required environment variables in a single file. This will save you from writing a potentially long
    docker run command.

  • After searching, I found that the syntax is
    docker run [OPTIONS] IMAGE [COMMAND] [ARG...]

  • In my case:
    1- [OPTIONS] will be --env-file
    2- IMAGE will be onlyoffice/documentserver
    3- [COMMAND] will be "/bin/sh -c /app/ds/…" Is this syntax is correct?
    4- [ARG...] ??? I need to know what exactly mean?

    CONTAINER ID IMAGE COMMAND CREATED STATUS
    PORTS NAMES
    5877bdecae84 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited (
    255) 26 minutes ago 80/tcp, 0.0.0.0:443->443/tcp inspiring_villani
    9a5ddbdcf6d4 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited (
    255) 26 minutes ago 0.0.0.0:80->80/tcp, 443/tcp dreamy_turing
    b7a86f4d3d19 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited
    (255) 8 hours ago 80/tcp, 0.0.0.0:443->443/tcp dreamy_albattani
    cf46e4e99c05 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited
    (255) 8 hours ago 0.0.0.0:80->80/tcp, 443/tcp silly_bhaskara
    3c6b80efed5c hello-world "/hello" 8 hours ago Exited (0) 8 hours ago
    vigila

  • I have SSL certification, SSL key and SSL dhparam paths.

  • I need to know the file that should collect these parameters:

    ONLYOFFICE_HTTPS_HSTS_ENABLED: Advanced configuration option for turning off the HSTS
    configuration. Applicable only when SSL is in use. Defaults to true.
    ONLYOFFICE_HTTPS_HSTS_MAXAGE: Advanced configuration option for setting the HSTS max-age
    in the onlyoffice nginx vHost configuration. Applicable only when SSL is in use. Defaults to
    31536000.
    SSL_CERTIFICATE_PATH: The path to the SSL certificate to use. Defaults to
    /var/www/onlyoffice/Data/certs/onlyoffice.crt.
    SSL_KEY_PATH: The path to the SSL certificate's private key. Defaults to
    /var/www/onlyoffice/Data/certs/onlyoffice.key.
    SSL_DHPARAM_PATH: The path to the Diffie-Hellman parameter. Defaults to
    /var/www/onlyoffice/Data/certs/dhparam.pem.
    SSL_VERIFY_CLIENT: Enable verification of client certificates using the CA_CERTIFICATES_PATH file.
    Defaults to false

    ONLYOFFICE Document Server OS :- Ubuntu 18.4 LTS.

Originally created by @Sys-Admin889 on GitHub (Mar 14, 2020). Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/232 Hello everyone, - I'm trying to install ONLYOFFICE Document Server and running it using HTTPS as the following [instructions ](https://github.com/ONLYOFFICE/Docker-DocumentServer). - I need to know how to configure parameters as described bellow? Please refer the docker run command options for the --env-file flag where you can specify all required environment variables in a single file. This will save you from writing a potentially long docker run command. - After searching, I found that the syntax is docker run [OPTIONS] IMAGE [COMMAND] [ARG...] - In my case: 1- [OPTIONS] will be --env-file 2- IMAGE will be onlyoffice/documentserver 3- [COMMAND] will be "/bin/sh -c /app/ds/…" Is this syntax is correct? 4- [ARG...] ??? I need to know what exactly mean? CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 5877bdecae84 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited ( 255) 26 minutes ago 80/tcp, 0.0.0.0:443->443/tcp inspiring_villani 9a5ddbdcf6d4 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited ( 255) 26 minutes ago 0.0.0.0:80->80/tcp, 443/tcp dreamy_turing b7a86f4d3d19 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited (255) 8 hours ago 80/tcp, 0.0.0.0:443->443/tcp dreamy_albattani cf46e4e99c05 onlyoffice/documentserver "/bin/sh -c /app/ds/…" 8 hours ago Exited (255) 8 hours ago 0.0.0.0:80->80/tcp, 443/tcp silly_bhaskara 3c6b80efed5c hello-world "/hello" 8 hours ago Exited (0) 8 hours ago vigila - I have SSL certification, SSL key and SSL dhparam paths. - I need to know the file that should collect these parameters: ONLYOFFICE_HTTPS_HSTS_ENABLED: Advanced configuration option for turning off the HSTS configuration. Applicable only when SSL is in use. Defaults to true. ONLYOFFICE_HTTPS_HSTS_MAXAGE: Advanced configuration option for setting the HSTS max-age in the onlyoffice nginx vHost configuration. Applicable only when SSL is in use. Defaults to 31536000. SSL_CERTIFICATE_PATH: The path to the SSL certificate to use. Defaults to /var/www/onlyoffice/Data/certs/onlyoffice.crt. SSL_KEY_PATH: The path to the SSL certificate's private key. Defaults to /var/www/onlyoffice/Data/certs/onlyoffice.key. SSL_DHPARAM_PATH: The path to the Diffie-Hellman parameter. Defaults to /var/www/onlyoffice/Data/certs/dhparam.pem. SSL_VERIFY_CLIENT: Enable verification of client certificates using the CA_CERTIFICATES_PATH file. Defaults to false ONLYOFFICE Document Server OS :- Ubuntu 18.4 LTS.
kerem 2026-02-26 09:36:44 +03:00
  • closed this issue
  • added the
    fixed
    label
Author
Owner

@ShockwaveNN commented on GitHub (Mar 16, 2020):

@ibnpetr can you help with ssl configuration?

<!-- gh-comment-id:599416460 --> @ShockwaveNN commented on GitHub (Mar 16, 2020): @ibnpetr can you help with ssl configuration?
Author
Owner

@Jay991 commented on GitHub (Jul 16, 2020):

I have the same issue

<!-- gh-comment-id:659436688 --> @Jay991 commented on GitHub (Jul 16, 2020): I have the same issue
Author
Owner

@jiacai-wang commented on GitHub (Oct 31, 2020):

struggling to enable https access too.

<!-- gh-comment-id:719939307 --> @jiacai-wang commented on GitHub (Oct 31, 2020): struggling to enable https access too.
Author
Owner

@jiacai-wang commented on GitHub (Nov 2, 2020):

I have got https to work on my ubuntu1804. It seemed that the pem file was to cause the issue in my case.
I used Ali Cloud service and the https cert gave me 2 crt, 1 key and 1 pem file.
I followed the struction in this github and applied self-generated cert and https worked fine.
When using my own ssl file from Ali Cloud, pem file seemed different from the self-generated pem. So I just used .crt and .key file from Ali, leaving pem file missing, then https worked fine.

<!-- gh-comment-id:720289675 --> @jiacai-wang commented on GitHub (Nov 2, 2020): I have got https to work on my ubuntu1804. It seemed that the pem file was to cause the issue in my case. I used Ali Cloud service and the https cert gave me 2 crt, 1 key and 1 pem file. I followed the struction in this github and applied self-generated cert and https worked fine. When using my own ssl file from Ali Cloud, pem file seemed different from the self-generated pem. So I just used .crt and .key file from Ali, leaving pem file missing, then https worked fine.
Author
Owner

@igwyd commented on GitHub (Nov 7, 2024):

The guide for swiching to HTTPS have changed and work correctly at this moment https://github.com/ONLYOFFICE/Docker-DocumentServer?tab=readme-ov-file#running-onlyoffice-document-server-using-https.

<!-- gh-comment-id:2461431333 --> @igwyd commented on GitHub (Nov 7, 2024): The guide for swiching to HTTPS have changed and work correctly at this moment https://github.com/ONLYOFFICE/Docker-DocumentServer?tab=readme-ov-file#running-onlyoffice-document-server-using-https.
Author
Owner

@Rita-Bubnova commented on GitHub (Nov 7, 2024):

I close this issue. Feel free to comment or reopen it if you got further questions.

<!-- gh-comment-id:2461561792 --> @Rita-Bubnova commented on GitHub (Nov 7, 2024): I close this issue. Feel free to comment or reopen it if you got further questions.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Docker-DocumentServer-ONLYOFFICE#128
No description provided.