File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -134,15 +134,23 @@ Special `omit` value will disable sending the header by the module.
134134
135135## Install
136136
137- ### CentOS/RHEL 6, 7, 8 or Amazon Linux 2
137+ We highly recommend installing using packages, where available,
138+ instead of compiling.
138139
139- It's easy to install the module in your stable NGINX instance dynamically:
140+ ### CentOS/RHEL 6, 7, 8; Amazon Linux 2 and Fedora packages
141+
142+ It's easy to install the module package for these operating systems.
143+
144+ ` ngx_security headers ` is part of the NGINX Extras collection, so you can install
145+ it alongside [ any modules] ( https://nginx-extras.getpagespeed.com/ ) ,
146+ including PageSpeed and Brotli.
140147
141148``` bash
142149sudo yum -y install https://extras.getpagespeed.com/release-latest.rpm
143150sudo yum -y install nginx-module-security-headers
144151```
145152
153+
146154Then add it at the top of your ` nginx.conf ` :
147155
148156``` nginx
@@ -158,6 +166,9 @@ load_module modules/ngx_http_modsecurity_module.so;
158166
159167### Other platforms
160168
169+ Compiling NGINX modules is [ prone to many problems] ( https://www.getpagespeed.com/server-setup/where-compilation-went-wrong ) ,
170+ including making your website insecure. Be sure to keep your NGINX and modules updated, if you go that route.
171+
161172To compile the module into NGINX, run:
162173
163174``` bash
You can’t perform that action at this time.
0 commit comments