SHARE
TWEET

nct

a guest Feb 14th, 2020 74 in 7 days
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Assuming this container is called "letsencrypt", edit your nextcloud container's config
  2. # located at /config/www/nextcloud/config/config.php and add the following lines before the ");":
  3. #  'trusted_proxies' => ['letsencrypt'],
  4. #  'overwritewebroot' => '/nextcloud',
  5. #  'overwrite.cli.url' => 'https://your-domain.com/nextcloud',
  6. #
  7. # Also don't forget to add your domain name to the trusted domains array. It should look somewhat like this:
  8. #  array (
  9. #    0 => '192.168.0.1:444', # This line may look different on your setup, don't modify it.
  10. #    1 => 'your-domain.com',
  11. #  ),
  12.  
  13. # Redirects for DAV clients
  14. location = /.well-known/carddav {
  15.     return 301 $scheme://$http_host/nextcloudtest/remote.php/dav;
  16. }
  17.  
  18. location = /.well-known/caldav {
  19.     return 301 $scheme://$http_host/nextcloudtest/remote.php/dav;
  20. }
  21.  
  22. location /nextcloudtest {
  23.     return 301 $scheme://$http_host/nextcloudtest/;
  24. }
  25.  
  26. location ^~ /nextcloudtest/ {
  27.     include /config/nginx/proxy.conf;
  28.     resolver 127.0.0.11 valid=30s;
  29.     set $upstream_nextcloudtest nextcloudtest;
  30.     rewrite /nextcloudtest(.*) $1 break;
  31.     proxy_pass https://$upstream_nextcloudtest:443;
  32.     proxy_max_temp_file_size 2048m;
  33.     proxy_set_header Range $http_range;
  34.     proxy_set_header If-Range $http_if_range;
  35.     proxy_set_header Connection $http_connection;
  36.     proxy_redirect off;
  37.     proxy_ssl_session_reuse off;
  38. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top