Closed ttalla14 closed 7 years ago
I think the module (https://github.com/openresty/headers-more-nginx-module) is not included anymore (or maybe you need nginx-extras).
You can check that with nginx -V.
@ttalla14 Please make sure that :
nginx-extras
. It's the only Nginx flavor that supports headers-morePlease let me know if it fixes your issue.
$apt-get install nginx-extras
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
nginx-common
Suggested packages:
fcgiwrap nginx-doc ssl-cert
The following NEW packages will be installed:
nginx-common nginx-extras
0 upgraded, 2 newly installed, 0 to remove and 31 not upgraded.
Need to get 0 B/683 kB of archives.
After this operation, 1,812 kB of additional disk space will be used.
Do you want to continue [Y/n]? Y
Preconfiguring packages ...
(Reading database ... 53468 files and directories currently installed.)
Preparing to unpack .../nginx-common_1.6.2-5+deb8u4_all.deb ...
Unpacking nginx-common (1.6.2-5+deb8u4) ...
dpkg: error processing archive /var/cache/apt/archives/nginx-common_1.6.2-5+deb8u4_all.deb (--unpack):
trying to overwrite '/etc/nginx/scgi_params', which is also in package nginx 1.10.2-1~jessie
Preparing to unpack .../nginx-extras_1.6.2-5+deb8u4_amd64.deb ...
Unpacking nginx-extras (1.6.2-5+deb8u4) ...
dpkg: error processing archive /var/cache/apt/archives/nginx-extras_1.6.2-5+deb8u4_amd64.deb (--unpack):
trying to overwrite '/usr/sbin/nginx', which is also in package nginx 1.10.2-1~jessie
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/nginx-common_1.6.2-5+deb8u4_all.deb
/var/cache/apt/archives/nginx-extras_1.6.2-5+deb8u4_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Why are you trying to install Nginx 1.6.2? These packages do not come from Dotdeb.
I don't know I just ran the command to install nginx-extras
Please make sure to have the Dotdeb lines in your sources.list before doing so.
Below lines are the sources.list file...
# deb cdrom:[Debian GNU/Linux 7.7.0 _Wheezy_ - Official amd64 NETINST Binary-1 20141018-13:04]/ jessie main
# deb cdrom:[Debian GNU/Linux 7.7.0 _Wheezy_ - Official amd64 NETINST Binary-1 20141018-13:04]/ jessie main
deb http://mirrors.kernel.org/debian jessie main
deb-src http://mirrors.kernel.org/debian jessie main
deb http://security.debian.org/ jessie/updates main
deb-src http://security.debian.org/ jessie/updates main
# jessie-updates, previously known as 'volatile'
deb http://mirrors.kernel.org/debian jessie-updates main
deb-src http://mirrors.kernel.org/debian jessie-updates main
deb http://nginx.org/packages/debian/ jessie nginx
deb-src http://nginx.org/packages/debian/ jessie nginx
No mention of Dotdeb in those...
Are you sure your issue comes from Dotdeb packages? Not from Nginx.org packages?
Hi, Here's my issue, I'm using nginx 1.7.7 previously and now I upgraded to latest stable 1.10.1. It went fine and when I run nginx -t to test... it errors the below, nginx: [emerg] unknown directive "more_set_headers" in /etc/nginx/sites-enabled/afterburner.conf:56 nginx: configuration file /etc/nginx/nginx.conf test failed
And at line 56 of afterburner.conf has the following line, location ~ .(eot|ttf|woff|css|js|html|gif)$ { 56 more_set_headers 'Access-Control-Allow-Origin: '; 57 }