NextCloud Installation Q & A

    • OMV 3.x

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • You can install it as a sub directory.
      The vhost codes are a little different, you have to do a little modification.

      Display Spoiler


      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000;
      2. includeSubDomains; preload;";
      3. add_header X-Content-Type-Options nosniff;
      4. add_header X-Frame-Options "SAMEORIGIN";
      5. add_header X-XSS-Protection "1; mode=block";
      6. add_header X-Robots-Tag none;
      7. add_header X-Download-Options noopen;
      8. add_header X-Permitted-Cross-Domain-Policies none;
      9. # Path to the root of your installation
      10. root /var/www/;
      11. location = /robots.txt {
      12. allow all;
      13. log_not_found off;
      14. access_log off;
      15. }
      16. # The following 2 rules are only needed for the user_webfinger app.
      17. # Uncomment it if you're planning to use this app.
      18. # rewrite ^/.well-known/host-meta /nextcloud/public.php?service=host-meta
      19. # last;
      20. #rewrite ^/.well-known/host-meta.json
      21. # /nextcloud/public.php?service=host-meta-json last;
      22. location = /.well-known/carddav {
      23. return 301 $scheme://$host/nextcloud/remote.php/dav;
      24. }
      25. location = /.well-known/caldav {
      26. return 301 $scheme://$host/nextcloud/remote.php/dav;
      27. }
      28. location /.well-known/acme-challenge { }
      29. location ^~ /nextcloud {
      30. # set max upload size
      31. client_max_body_size 50G;
      32. fastcgi_buffers 64 4K;
      33. # Disable gzip to avoid the removal of the ETag header
      34. gzip off;
      35. # Uncomment if your server is build with the ngx_pagespeed module
      36. # This module is currently not supported.
      37. #pagespeed off;
      38. error_page 403 /nextcloud/core/templates/403.php;
      39. error_page 404 /nextcloud/core/templates/404.php;
      40. location /nextcloud {
      41. rewrite ^ /nextcloud/index.php$uri;
      42. }
      43. location ~ ^/nextcloud/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      44. deny all;
      45. }
      46. location ~ ^/nextcloud/(?:\.|autotest|occ|issue|indie|db_|console) {
      47. deny all;
      48. }
      49. location ~ ^/nextcloud/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      50. include fastcgi_params;
      51. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      52. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      53. fastcgi_param PATH_INFO $fastcgi_path_info;
      54. fastcgi_param HTTPS on;
      55. #Avoid sending the security headers twice
      56. fastcgi_param modHeadersAvailable true;
      57. fastcgi_param front_controller_active true;
      58. fastcgi_pass $socket;
      59. fastcgi_intercept_errors on;
      60. fastcgi_request_buffering off;
      61. }
      62. location ~ ^/nextcloud/(?:updater|ocs-provider)(?:$|/) {
      63. try_files $uri/ =404;
      64. index index.php;
      65. }
      66. # Adding the cache control header for js and css files
      67. # Make sure it is BELOW the PHP block
      68. location ~* \.(?:css|js|woff|svg|gif)$ {
      69. try_files $uri /nextcloud/index.php$uri$is_args$args;
      70. add_header Cache-Control "public, max-age=7200";
      71. # Add headers to serve security related headers (It is intended
      72. # to have those duplicated to the ones above)
      73. # Before enabling Strict-Transport-Security headers please read
      74. # into this topic first.
      75. add_header Strict-Transport-Security "max-age=15768000;
      76. includeSubDomains; preload;";
      77. add_header X-Content-Type-Options nosniff;
      78. add_header X-Frame-Options "SAMEORIGIN";
      79. add_header X-XSS-Protection "1; mode=block";
      80. add_header X-Robots-Tag none;
      81. add_header X-Download-Options noopen;
      82. add_header X-Permitted-Cross-Domain-Policies none;
      83. # Optional: Don't log access to assets
      84. access_log off;
      85. }
      86. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      87. try_files $uri /nextcloud/index.php$uri$is_args$args;
      88. # Optional: Don't log access to other assets
      89. access_log off;
      90. }
      Display All
      OMV v4.0
      Asus Z97-A/3.1; i3-4370
      32GB RAM Corsair Vengeance Pro
      4x3TB RAID10

      The post was edited 1 time, last by tinh_x7 ().

    • tinh_x7 wrote:

      You can install it as a sub directory.
      The vhost codes are a little different, you have to do a little modification.

      Display Spoiler


      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000;
      2. includeSubDomains; preload;";
      3. add_header X-Content-Type-Options nosniff;
      4. add_header X-Frame-Options "SAMEORIGIN";
      5. add_header X-XSS-Protection "1; mode=block";
      6. add_header X-Robots-Tag none;
      7. add_header X-Download-Options noopen;
      8. add_header X-Permitted-Cross-Domain-Policies none;
      9. # Path to the root of your installation
      10. root /var/www/;
      11. location = /robots.txt {
      12. allow all;
      13. log_not_found off;
      14. access_log off;
      15. }
      16. # The following 2 rules are only needed for the user_webfinger app.
      17. # Uncomment it if you're planning to use this app.
      18. # rewrite ^/.well-known/host-meta /nextcloud/public.php?service=host-meta
      19. # last;
      20. #rewrite ^/.well-known/host-meta.json
      21. # /nextcloud/public.php?service=host-meta-json last;
      22. location = /.well-known/carddav {
      23. return 301 $scheme://$host/nextcloud/remote.php/dav;
      24. }
      25. location = /.well-known/caldav {
      26. return 301 $scheme://$host/nextcloud/remote.php/dav;
      27. }
      28. location /.well-known/acme-challenge { }
      29. location ^~ /nextcloud {
      30. # set max upload size
      31. client_max_body_size 50G;
      32. fastcgi_buffers 64 4K;
      33. # Disable gzip to avoid the removal of the ETag header
      34. gzip off;
      35. # Uncomment if your server is build with the ngx_pagespeed module
      36. # This module is currently not supported.
      37. #pagespeed off;
      38. error_page 403 /nextcloud/core/templates/403.php;
      39. error_page 404 /nextcloud/core/templates/404.php;
      40. location /nextcloud {
      41. rewrite ^ /nextcloud/index.php$uri;
      42. }
      43. location ~ ^/nextcloud/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      44. deny all;
      45. }
      46. location ~ ^/nextcloud/(?:\.|autotest|occ|issue|indie|db_|console) {
      47. deny all;
      48. }
      49. location ~ ^/nextcloud/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      50. include fastcgi_params;
      51. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      52. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      53. fastcgi_param PATH_INFO $fastcgi_path_info;
      54. fastcgi_param HTTPS on;
      55. #Avoid sending the security headers twice
      56. fastcgi_param modHeadersAvailable true;
      57. fastcgi_param front_controller_active true;
      58. fastcgi_pass $socket;
      59. fastcgi_intercept_errors on;
      60. fastcgi_request_buffering off;
      61. }
      62. location ~ ^/nextcloud/(?:updater|ocs-provider)(?:$|/) {
      63. try_files $uri/ =404;
      64. index index.php;
      65. }
      66. # Adding the cache control header for js and css files
      67. # Make sure it is BELOW the PHP block
      68. location ~* \.(?:css|js|woff|svg|gif)$ {
      69. try_files $uri /nextcloud/index.php$uri$is_args$args;
      70. add_header Cache-Control "public, max-age=7200";
      71. # Add headers to serve security related headers (It is intended
      72. # to have those duplicated to the ones above)
      73. # Before enabling Strict-Transport-Security headers please read
      74. # into this topic first.
      75. add_header Strict-Transport-Security "max-age=15768000;
      76. includeSubDomains; preload;";
      77. add_header X-Content-Type-Options nosniff;
      78. add_header X-Frame-Options "SAMEORIGIN";
      79. add_header X-XSS-Protection "1; mode=block";
      80. add_header X-Robots-Tag none;
      81. add_header X-Download-Options noopen;
      82. add_header X-Permitted-Cross-Domain-Policies none;
      83. # Optional: Don't log access to assets
      84. access_log off;
      85. }
      86. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      87. try_files $uri /nextcloud/index.php$uri$is_args$args;
      88. # Optional: Don't log access to other assets
      89. access_log off;
      90. }
      Display All


      Can you explain a little more how you can do that please ?

      I've just tried to create a website dedicated to nextcloud via the nginx plugin with your settings but unfortunately it doesn't work.

      You wil find below my nextcloud vhost conf.

      Thanks for your help.

      Source Code

      1. server {
      2. listen 443 ssl;
      3. listen [::]:443 ssl;
      4. ssl_certificate /etc/ssl/certs/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.crt;
      5. ssl_certificate_key /etc/ssl/private/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.key;
      6. server_name mondomaine.com/nextcloud mondomainelocal.home/nextcloud;
      7. set $root_path "/media/a7acf08a-5ba4-4e2c-aa71-089f7ed18b5c/Web/Nextcloud";
      8. index index.html index.php;
      9. set $socket "unix:/var/run/fpm-0e0cd310-e349-4a9e-801a-046c86e7c607.sock";
      10. access_log /var/log/nginx/4cce4fca-5837-485e-8941-65ec9e682f37-access.log;
      11. error_log /var/log/nginx/4cce4fca-5837-485e-8941-65ec9e682f37-error.log;
      12. large_client_header_buffers 4 8k;
      13. add_header Strict-Transport-Security "max-age=15768000;
      14. includeSubDomains; preload;";
      15. add_header X-Content-Type-Options nosniff;
      16. add_header X-Frame-Options "SAMEORIGIN";
      17. add_header X-XSS-Protection "1; mode=block";
      18. add_header X-Robots-Tag none;
      19. add_header X-Download-Options noopen;
      20. add_header X-Permitted-Cross-Domain-Policies none;
      21. # Path to the root of your installation
      22. root /var/www/;
      23. location = /robots.txt {
      24. allow all;
      25. log_not_found off;
      26. access_log off;
      27. }
      28. # The following 2 rules are only needed for the user_webfinger app.
      29. # Uncomment it if you're planning to use this app.
      30. # rewrite ^/.well-known/host-meta /nextcloud/public.php?service=host-meta
      31. # last;
      32. #rewrite ^/.well-known/host-meta.json
      33. # /nextcloud/public.php?service=host-meta-json last;
      34. location = /.well-known/carddav {
      35. return 301 $scheme://$host/nextcloud/remote.php/dav;
      36. }
      37. location = /.well-known/caldav {
      38. return 301 $scheme://$host/nextcloud/remote.php/dav;
      39. }
      40. location /.well-known/acme-challenge { }
      41. location ^~ /nextcloud {
      42. # set max upload size
      43. client_max_body_size 50G;
      44. fastcgi_buffers 64 4K;
      45. # Disable gzip to avoid the removal of the ETag header
      46. gzip off;
      47. # Uncomment if your server is build with the ngx_pagespeed module
      48. # This module is currently not supported.
      49. #pagespeed off;
      50. error_page 403 /nextcloud/core/templates/403.php;
      51. error_page 404 /nextcloud/core/templates/404.php;
      52. location /nextcloud {
      53. rewrite ^ /nextcloud/index.php$uri;
      54. }
      55. location ~ ^/nextcloud/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      56. deny all;
      57. }
      58. location ~ ^/nextcloud/(?:\.|autotest|occ|issue|indie|db_|console) {
      59. deny all;
      60. }
      61. location ~ ^/nextcloud/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      62. include fastcgi_params;
      63. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      64. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      65. fastcgi_param PATH_INFO $fastcgi_path_info;
      66. fastcgi_param HTTPS on;
      67. #Avoid sending the security headers twice
      68. fastcgi_param modHeadersAvailable true;
      69. fastcgi_param front_controller_active true;
      70. fastcgi_pass $socket;
      71. fastcgi_intercept_errors on;
      72. }
      73. location ~ ^/nextcloud/(?:updater|ocs-provider)(?:$|/) {
      74. try_files $uri/ =404;
      75. index index.php;
      76. }
      77. # Adding the cache control header for js and css files
      78. # Make sure it is BELOW the PHP block
      79. location ~* \.(?:css|js|woff|svg|gif)$ {
      80. try_files $uri /nextcloud/index.php$uri$is_args$args;
      81. add_header Cache-Control "public, max-age=7200";
      82. # Add headers to serve security related headers (It is intended
      83. # to have those duplicated to the ones above)
      84. # Before enabling Strict-Transport-Security headers please read
      85. # into this topic first.
      86. add_header Strict-Transport-Security "max-age=15768000;
      87. includeSubDomains; preload;";
      88. add_header X-Content-Type-Options nosniff;
      89. add_header X-Frame-Options "SAMEORIGIN";
      90. add_header X-XSS-Protection "1; mode=block";
      91. add_header X-Robots-Tag none;
      92. add_header X-Download-Options noopen;
      93. add_header X-Permitted-Cross-Domain-Policies none;
      94. # Optional: Don't log access to assets
      95. access_log off;
      96. }
      97. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      98. try_files $uri /nextcloud/index.php$uri$is_args$args;
      99. # Optional: Don't log access to other assets
      100. access_log off;
      101. }
      102. }
      103. }
      Display All
    • tinh_x7 wrote:

      You can install it as a sub directory.
      The vhost codes are a little different, you have to do a little modification.

      Display Spoiler


      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000;
      2. includeSubDomains; preload;";
      3. add_header X-Content-Type-Options nosniff;
      4. add_header X-Frame-Options "SAMEORIGIN";
      5. add_header X-XSS-Protection "1; mode=block";
      6. add_header X-Robots-Tag none;
      7. add_header X-Download-Options noopen;
      8. add_header X-Permitted-Cross-Domain-Policies none;
      9. # Path to the root of your installation
      10. root /var/www/;
      11. location = /robots.txt {
      12. allow all;
      13. log_not_found off;
      14. access_log off;
      15. }
      16. # The following 2 rules are only needed for the user_webfinger app.
      17. # Uncomment it if you're planning to use this app.
      18. # rewrite ^/.well-known/host-meta /nextcloud/public.php?service=host-meta
      19. # last;
      20. #rewrite ^/.well-known/host-meta.json
      21. # /nextcloud/public.php?service=host-meta-json last;
      22. location = /.well-known/carddav {
      23. return 301 $scheme://$host/nextcloud/remote.php/dav;
      24. }
      25. location = /.well-known/caldav {
      26. return 301 $scheme://$host/nextcloud/remote.php/dav;
      27. }
      28. location /.well-known/acme-challenge { }
      29. location ^~ /nextcloud {
      30. # set max upload size
      31. client_max_body_size 50G;
      32. fastcgi_buffers 64 4K;
      33. # Disable gzip to avoid the removal of the ETag header
      34. gzip off;
      35. # Uncomment if your server is build with the ngx_pagespeed module
      36. # This module is currently not supported.
      37. #pagespeed off;
      38. error_page 403 /nextcloud/core/templates/403.php;
      39. error_page 404 /nextcloud/core/templates/404.php;
      40. location /nextcloud {
      41. rewrite ^ /nextcloud/index.php$uri;
      42. }
      43. location ~ ^/nextcloud/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      44. deny all;
      45. }
      46. location ~ ^/nextcloud/(?:\.|autotest|occ|issue|indie|db_|console) {
      47. deny all;
      48. }
      49. location ~ ^/nextcloud/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      50. include fastcgi_params;
      51. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      52. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      53. fastcgi_param PATH_INFO $fastcgi_path_info;
      54. fastcgi_param HTTPS on;
      55. #Avoid sending the security headers twice
      56. fastcgi_param modHeadersAvailable true;
      57. fastcgi_param front_controller_active true;
      58. fastcgi_pass $socket;
      59. fastcgi_intercept_errors on;
      60. fastcgi_request_buffering off;
      61. }
      62. location ~ ^/nextcloud/(?:updater|ocs-provider)(?:$|/) {
      63. try_files $uri/ =404;
      64. index index.php;
      65. }
      66. # Adding the cache control header for js and css files
      67. # Make sure it is BELOW the PHP block
      68. location ~* \.(?:css|js|woff|svg|gif)$ {
      69. try_files $uri /nextcloud/index.php$uri$is_args$args;
      70. add_header Cache-Control "public, max-age=7200";
      71. # Add headers to serve security related headers (It is intended
      72. # to have those duplicated to the ones above)
      73. # Before enabling Strict-Transport-Security headers please read
      74. # into this topic first.
      75. add_header Strict-Transport-Security "max-age=15768000;
      76. includeSubDomains; preload;";
      77. add_header X-Content-Type-Options nosniff;
      78. add_header X-Frame-Options "SAMEORIGIN";
      79. add_header X-XSS-Protection "1; mode=block";
      80. add_header X-Robots-Tag none;
      81. add_header X-Download-Options noopen;
      82. add_header X-Permitted-Cross-Domain-Policies none;
      83. # Optional: Don't log access to assets
      84. access_log off;
      85. }
      86. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      87. try_files $uri /nextcloud/index.php$uri$is_args$args;
      88. # Optional: Don't log access to other assets
      89. access_log off;
      90. }
      Display All



      Can you explain a little more how you can do that please ?


      I've
      just tried to create a website dedicated to nextcloud via the nginx
      plugin with your settings but unfortunately it doesn't work.


      You wil find below my nextcloud vhost conf.


      Thanks for your help.

      Display Spoiler

      Source Code

      1. server {
      2. listen 443 ssl;
      3. listen [::]:443 ssl;
      4. ssl_certificate /etc/ssl/certs/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.crt;
      5. ssl_certificate_key /etc/ssl/private/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.key;
      6. server_name mondomaine.com/nextcloud mondomainelocal.home/nextcloud;
      7. set $root_path "/media/a7acf08a-5ba4-4e2c-aa71-089f7ed18b5c/Web/Nextcloud";
      8. index index.html index.php;
      9. set $socket "unix:/var/run/fpm-0e0cd310-e349-4a9e-801a-046c86e7c607.sock";
      10. access_log /var/log/nginx/4cce4fca-5837-485e-8941-65ec9e682f37-access.log;
      11. error_log /var/log/nginx/4cce4fca-5837-485e-8941-65ec9e682f37-error.log;
      12. large_client_header_buffers 4 8k;
      13. add_header Strict-Transport-Security "max-age=15768000;
      14. includeSubDomains; preload;";
      15. add_header X-Content-Type-Options nosniff;
      16. add_header X-Frame-Options "SAMEORIGIN";
      17. add_header X-XSS-Protection "1; mode=block";
      18. add_header X-Robots-Tag none;
      19. add_header X-Download-Options noopen;
      20. add_header X-Permitted-Cross-Domain-Policies none;
      21. # Path to the root of your installation
      22. root /var/www/;
      23. location = /robots.txt {
      24. allow all;
      25. log_not_found off;
      26. access_log off;
      27. }
      28. # The following 2 rules are only needed for the user_webfinger app.
      29. # Uncomment it if you're planning to use this app.
      30. # rewrite ^/.well-known/host-meta /nextcloud/public.php?service=host-meta
      31. # last;
      32. #rewrite ^/.well-known/host-meta.json
      33. # /nextcloud/public.php?service=host-meta-json last;
      34. location = /.well-known/carddav {
      35. return 301 $scheme://$host/nextcloud/remote.php/dav;
      36. }
      37. location = /.well-known/caldav {
      38. return 301 $scheme://$host/nextcloud/remote.php/dav;
      39. }
      40. location /.well-known/acme-challenge { }
      41. location ^~ /nextcloud {
      42. # set max upload size
      43. client_max_body_size 50G;
      44. fastcgi_buffers 64 4K;
      45. # Disable gzip to avoid the removal of the ETag header
      46. gzip off;
      47. # Uncomment if your server is build with the ngx_pagespeed module
      48. # This module is currently not supported.
      49. #pagespeed off;
      50. error_page 403 /nextcloud/core/templates/403.php;
      51. error_page 404 /nextcloud/core/templates/404.php;
      52. location /nextcloud {
      53. rewrite ^ /nextcloud/index.php$uri;
      54. }
      55. location ~ ^/nextcloud/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      56. deny all;
      57. }
      58. location ~ ^/nextcloud/(?:\.|autotest|occ|issue|indie|db_|console) {
      59. deny all;
      60. }
      61. location ~ ^/nextcloud/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      62. include fastcgi_params;
      63. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      64. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      65. fastcgi_param PATH_INFO $fastcgi_path_info;
      66. fastcgi_param HTTPS on;
      67. #Avoid sending the security headers twice
      68. fastcgi_param modHeadersAvailable true;
      69. fastcgi_param front_controller_active true;
      70. fastcgi_pass $socket;
      71. fastcgi_intercept_errors on;
      72. }
      73. location ~ ^/nextcloud/(?:updater|ocs-provider)(?:$|/) {
      74. try_files $uri/ =404;
      75. index index.php;
      76. }
      77. # Adding the cache control header for js and css files
      78. # Make sure it is BELOW the PHP block
      79. location ~* \.(?:css|js|woff|svg|gif)$ {
      80. try_files $uri /nextcloud/index.php$uri$is_args$args;
      81. add_header Cache-Control "public, max-age=7200";
      82. # Add headers to serve security related headers (It is intended
      83. # to have those duplicated to the ones above)
      84. # Before enabling Strict-Transport-Security headers please read
      85. # into this topic first.
      86. add_header Strict-Transport-Security "max-age=15768000;
      87. includeSubDomains; preload;";
      88. add_header X-Content-Type-Options nosniff;
      89. add_header X-Frame-Options "SAMEORIGIN";
      90. add_header X-XSS-Protection "1; mode=block";
      91. add_header X-Robots-Tag none;
      92. add_header X-Download-Options noopen;
      93. add_header X-Permitted-Cross-Domain-Policies none;
      94. # Optional: Don't log access to assets
      95. access_log off;
      96. }
      97. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      98. try_files $uri /nextcloud/index.php$uri$is_args$args;
      99. # Optional: Don't log access to other assets
      100. access_log off;
      101. }
      102. }
      103. }
      Display All

    • krutojmax wrote:

      tinh_x7 wrote:

      @kruto,

      I think this could be a bug on Galaxy S7 edge, are you using the browser or a NC app?
      I don't have this issue on my iPhone.

      FYI: those codes are for OwnCloud.
      I use the NC app.

      I know, that this codes are for oc, but it works for nc too. And it works with my s7e. I don't know what the different is but it works :)

      I have got the same issue!
      Any clue how to fix this?

      Gesendet von meinem MHA-L29 mit Tapatalk
    • Try this, in your current vhost config, change these two codes order, and restart your Nginx service.

      Edit: I've updated the vhost codes in the tutorial.

      From line 56, & line 57 (yours maybe different).

      Source Code

      1. include fastcgi_params;
      2. fastcgi_split_path_info ^(.+\.php)(/.*)$;

      to:

      Source Code

      1. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      2. include fastcgi_params;
      OMV v4.0
      Asus Z97-A/3.1; i3-4370
      32GB RAM Corsair Vengeance Pro
      4x3TB RAID10

      The post was edited 6 times, last by tinh_x7 ().

    • tinh_x7 wrote:

      Your vhost is incorrect.

      Why you don't setup like the instructions written?
      Why it has to be in sub-directory?

      I'd like to configure nextcloud in a sub-directory to avoid to open many ports in my router. It works if I configure it with a subdomain (cloud.mydomain.com) but I haven't a payed domain where I could define a DNS Zone (just a DynDNS domain which points to my dynamic public IP). That's why I asked you if it were possible to configure nextcloud in a sub directory like mydomain.com/nextcloud where mydomain.com points to the main OMV Webui.

      Sorry if I was not clear in my first post.

      Thanks for your help.

      The post was edited 2 times, last by Raptor039 ().

    • makromorphago wrote:

      krutojmax wrote:

      tinh_x7 wrote:

      @kruto,

      I think this could be a bug on Galaxy S7 edge, are you using the browser or a NC app?
      I don't have this issue on my iPhone.

      FYI: those codes are for OwnCloud.
      I use the NC app.
      I know, that this codes are for oc, but it works for nc too. And it works with my s7e. I don't know what the different is but it works :)
      I have got the same issue!
      Any clue how to fix this?

      Gesendet von meinem MHA-L29 mit Tapatalk
      Hi !

      I'm just finding the workaround by analysing logs of the nextlcoud android app via logcat. It's a bug in the HTTP library of the app. If you want to pass out that, you have to comment or delete in your vhost conf the following lines (both at the begining and at the end of the conf) :

      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000;
      2. includeSubDomains; preload;";

      Here my vhost wich works with android app :

      Source Code

      1. server {
      2. listen 8443 ssl;
      3. listen [::]:8443 ssl;
      4. ssl_certificate /etc/ssl/certs/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.crt;
      5. ssl_certificate_key /etc/ssl/private/openmediavault-46b02146-8604-4b3a-9a43-bacdd61abaa6.key;
      6. set $root_path "/media/a7acf08a-5ba4-4e2c-aa71-089f7ed18b5c/Web/Nextcloud";
      7. root $root_path;
      8. index index.html index.php;
      9. set $socket "unix:/var/run/fpm-0e0cd310-e349-4a9e-801a-046c86e7c607.sock";
      10. access_log /var/log/nginx/b7d03072-5e29-48e5-a12d-ed6e1a47ba7a-access.log;
      11. error_log /var/log/nginx/b7d03072-5e29-48e5-a12d-ed6e1a47ba7a-error.log;
      12. large_client_header_buffers 4 8k;
      13. #add_header Strict-Transport-Security "max-age=15768000;
      14. #includeSubDomains; preload;";
      15. add_header X-Content-Type-Options nosniff;
      16. add_header X-Frame-Options "SAMEORIGIN";
      17. add_header X-XSS-Protection "1; mode=block";
      18. add_header X-Robots-Tag none;
      19. add_header X-Download-Options noopen;
      20. add_header X-Permitted-Cross-Domain-Policies none;
      21. location = /robots.txt {
      22. log_not_found off;
      23. allow all;
      24. access_log off;
      25. }
      26. # The following 2 rules are only needed for the user_webfinger app.
      27. # Uncomment it if you're planning to use this app.
      28. #rewrite ^/.well-known/host-meta /public.php?service=host-meta last;
      29. #rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json
      30. # last;
      31. location = /.well-known/carddav {
      32. return 301 $scheme://$host/remote.php/dav;
      33. }
      34. location = /.well-known/caldav {
      35. return 301 $scheme://$host/remote.php/dav;
      36. }
      37. # set max upload size
      38. client_max_body_size 50G;
      39. fastcgi_buffers 64 4K;
      40. # Disable gzip to avoid the removal of the ETag header
      41. gzip off;
      42. # Uncomment if your server is build with the ngx_pagespeed module
      43. # This module is currently not supported.
      44. #pagespeed off;
      45. error_page 403 /core/templates/403.php;
      46. error_page 404 /core/templates/404.php;
      47. location / {
      48. rewrite ^ /index.php$uri;
      49. }
      50. location ~ ^/(?:build|tests|config|lib|3rdparty|templates|data)/ {
      51. deny all;
      52. }
      53. location ~ ^/(?:\.|autotest|occ|issue|indie|db_|console) {
      54. deny all;
      55. }
      56. location ~ ^/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|ocs-provider/.+|core/templates/40[34])\.php(?:$|/) {
      57. fastcgi_split_path_info ^(.+\.php)(/.*)$;
      58. include fastcgi_params;
      59. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
      60. fastcgi_param PATH_INFO $fastcgi_path_info;
      61. fastcgi_param HTTPS on;
      62. #Avoid sending the security headers twice
      63. fastcgi_param modHeadersAvailable true;
      64. fastcgi_param front_controller_active true;
      65. fastcgi_pass $socket;
      66. fastcgi_intercept_errors on;
      67. }
      68. location ~ ^/(?:updater|ocs-provider)(?:$|/) {
      69. try_files $uri/ =404;
      70. index index.php;
      71. }
      72. # Adding the cache control header for js and css files
      73. # Make sure it is BELOW the PHP block
      74. location ~* \.(?:css|js|woff|svg|gif)$ {
      75. try_files $uri /index.php$uri$is_args$args;
      76. add_header Cache-Control "public, max-age=7200";
      77. #add_header Strict-Transport-Security "max-age=15768000;
      78. #includeSubDomains; preload;";
      79. add_header X-Content-Type-Options nosniff;
      80. add_header X-Frame-Options "SAMEORIGIN";
      81. add_header X-XSS-Protection "1; mode=block";
      82. add_header X-Robots-Tag none;
      83. add_header X-Download-Options noopen;
      84. add_header X-Permitted-Cross-Domain-Policies none;
      85. # Optional: Don't log access to assets
      86. access_log off;
      87. }
      88. location ~* \.(?:png|html|ttf|ico|jpg|jpeg)$ {
      89. try_files $uri /index.php$uri$is_args$args;
      90. # Optional: Don't log access to other assets
      91. access_log off;
      92. }
      93. }
      Display All


      tinh_x7 wrote:

      Have you try this?

      It's in the config.php
      'overwrite.cli.url' => 'https://<your server name>/cloud',
      When I'm using a subfolder configuration, I can't access to the install wizard, get a 404 error page. Now my issue with the Android app is solved, I will try to make it work this afternoon.

      The post was edited 1 time, last by Raptor039 ().

    • Regarding the 404 error page, the solution that I posted above work for Android users from GitHub.
      If you comment or remove the add_header Strict-Transport-Security....., you may receive a security warning in your NC log.
      This issue so far has reported only on Android devices.

      Have you try it?

      You can test with the OC codes that I posted on page 1, and added the 'security header to it' to see if you receive the same error.

      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000;
      2. includeSubDomains; preload;";
      OMV v4.0
      Asus Z97-A/3.1; i3-4370
      32GB RAM Corsair Vengeance Pro
      4x3TB RAID10

      The post was edited 1 time, last by tinh_x7 ().

    • You're right, I had a security warning in my nextcloud admin panel but now errors are gone !

      The config format was the real issue !

      HSTS headers have to be written in a single line in the vhost conf to work with android app !! (It drives me crazy...) :

      Source Code

      1. add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;";
    • Interesting.
      Android so picky, huh...

      So, if you're an Android users, and you using a sub domain, and the header security codes are in two lines, then you get that error.
      The original vhost config has two issues, but now it's been fixed.
      OMV v4.0
      Asus Z97-A/3.1; i3-4370
      32GB RAM Corsair Vengeance Pro
      4x3TB RAID10

      The post was edited 1 time, last by tinh_x7 ().

    • tinh_x7 wrote:

      I found an alternative lightweight of NextCloud & Owncloud, and it calls: FileRun.
      It looks similar to Google Drive.

      You can check it out and report your feedback here.

      filerun.com/

      Demo:
      demo.filerun.com/#/HOME

      Installation Guide:
      docs.filerun.com/filerun_install_guide


      [IMG:https://www.filerun.com/images/screenshot.jpg?v=2017_01]
      Hi thank you for your awesome guide.

      I am really new in using Linux and your guide helped me a lot. I came from xpenology to omv and xpenology was easier to use. As I was reading the thread I saw your FileRun post and I really like it. I was wondering if you could also write a guide how to install FileRun on omv or use its docker.

      Thanks a lot

      Ludwig
    • hi,

      as i am a Linux noob I have a nother question.
      i installed the extrenal storage plugin on NExtcloud but when i open it it says SMBclient is not installed.
      I also have a External Harddrive formated in NTFS connected over USB and i would like to have access over NExtcloud on it.
      How can i bind That External HDD in to NExtcloud.

      Thanks for the Help
    • Enter this command in Putty:
      sudo apt-get install smbclient

      Then restart your Nginx:
      service nginx restart

      Regarding your external drive, not sure if NTFS works with NC, but you can try to mount it as local storage.
      If not, then you need to copy the data somewhere temporarily, and convert it to ext4 format.

      [IMG:https://docs.nextcloud.com/server/9/admin_manual/_images/local.png]


      Source Code

      1. In the Folder name field enter the folder name that you want to appear on your Nextcloud Files page.
      2. In the Configuration field enter the full filepath of the directory you want to mount.
      3. In the Available for field enter the users or groups who have permission to access the mount. By default all users have access.
      OMV v4.0
      Asus Z97-A/3.1; i3-4370
      32GB RAM Corsair Vengeance Pro
      4x3TB RAID10

      The post was edited 2 times, last by tinh_x7 ().

    • @pichimoo when you need a smb connection you must install smbclient in a comandline or with a apt tool plugin but i hav test it and find out it need many resauces.
      I have linkt my local data foulder with /media/UUID/fouldername. It's the best solucion for me

      Edit: i was on page 4 and dont see se answer of tinh_x7. but it is the same ;)
      omv 4.0.19 | 64 bit | omvextrasorg 4.1.2 | kernel 4.14
      used plugins: nginx | mysql | docker-gui |rsnapshot | antivirus | apt tool | letsEncrypt |
      used other: netxtcloud | logitechmediaserver | emby
    • Users Online 1

      1 Guest