enable_strict_transport_security_apache_virtual_host
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
enable_strict_transport_security_apache_virtual_host [2023/06/24 17:04] – wikiadmin | enable_strict_transport_security_apache_virtual_host [2023/06/24 17:14] (current) – wikiadmin | ||
---|---|---|---|
Line 18: | Line 18: | ||
This example configuration will make all subdomains only accessible via HTTPS. If you have subdomains not accessible via HTTPS, remove includeSubDomains. | This example configuration will make all subdomains only accessible via HTTPS. If you have subdomains not accessible via HTTPS, remove includeSubDomains. | ||
- | IMPORTANT: | + | **IMPORTANT: |
- | Let's see how to enable headers module using a2enmod | + | ===== Here’s how to enable mod_headers in Apache Ubuntu / Debian |
- | + | ||
- | How to Enable mod_headers in Apache Ubuntu | + | |
- | Here’s how to enable mod_headers in Apache Ubuntu / Debian. | + | |
1. Install mod_headers | 1. Install mod_headers | ||
Line 36: | Line 33: | ||
< | < | ||
$ sudo a2enmod headers | $ sudo a2enmod headers | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | $ sudo a2enmod headers | ||
+ | </ | ||
+ | |||
+ | Result: | ||
+ | |||
+ | < | ||
+ | Enabling module headers. | ||
+ | To activate the new configuration, | ||
+ | systemctl restart apache2 | ||
+ | $ | ||
</ | </ | ||
2. Restart Apache web server for changes to take effect | 2. Restart Apache web server for changes to take effect | ||
+ | < | ||
+ | $ sudo systemctl restart apache2 | ||
+ | </ | ||
+ | |||
+ | OR | ||
+ | |||
+ | < | ||
$ sudo service apache2 restart | $ sudo service apache2 restart | ||
+ | </ | ||
3. Check if mod_headers is working. | 3. Check if mod_headers is working. |
enable_strict_transport_security_apache_virtual_host.1687626269.txt.gz · Last modified: 2023/06/24 17:04 by wikiadmin