Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

49 linhas
1.1KB

  1. {{ ansible_managed | comment }}
  2. <VirtualHost *:443 *:8843>
  3. ServerName {{nextcloud_server_names|first}}
  4. {% for name in nextcloud_server_names | difference([nextcloud_server_names|first]) %}
  5. ServerAlias {{name}}
  6. {% endfor %}
  7. SSLEngine on
  8. SSLCertificateFile "/etc/ssl/certs/nextcloud.cert.pem"
  9. SSLCertificateKeyFile "/etc/ssl/private/nextcloud.key.pem"
  10. {% if not certificate_provider == "selfsigned" %}
  11. SSLCertificateChainFile "/etc/ssl/certs/nextcloud.chain.pem"
  12. {% endif %}
  13. DocumentRoot {{nextcloud_directory}}
  14. <Directory {{nextcloud_directory}}/>
  15. Options +FollowSymlinks
  16. AllowOverride All
  17. <IfModule mod_dav.c>
  18. Dav off
  19. </IfModule>
  20. SetEnv HOME {{nextcloud_directory}}
  21. SetEnv HTTP_HOME {{nextcloud_directory}}
  22. </Directory>
  23. ErrorLog ${APACHE_LOG_DIR}/error.log
  24. CustomLog ${APACHE_LOG_DIR}/access.log combined
  25. </VirtualHost>
  26. <VirtualHost *:80>
  27. ServerName {{nextcloud_server_names|first}}
  28. {% for name in nextcloud_server_names | difference(nextcloud_server_names|first) %}
  29. ServerAlias {{name}}
  30. {% endfor %}
  31. RewriteEngine On
  32. RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
  33. </VirtualHost>