I currently have Debian bullseye distribution installed (Pi 4 device, Raspberry Pi OS bullseye, arm64).
This device is part of an office server environment for which there is an nginx web server instance running.
The latest version of nginx available for bullseye is 1.18, and now I want to upgrade it.
I followed the official procedure detailed here (I chose the mainline packages option): https://nginx.org/en/linux_packages.html#Debian
I did add the package pinning file as indicated:
$ more /etc/apt/preferences.d/99nginx
Package: *
Pin: origin nginx.org
Pin: release o=nginx
Pin-Priority: 900
When I issue
sudo apt update
apt-cache policy nginx nginx-common nginx-extras
it shows the following:
nginx:
Installed: (none)
Candidate: 1.29.3-1~bullseye
Version table:
1.29.3-1~bullseye 900
900 http://nginx.org/packages/mainline/debian bullseye/nginx arm64 Packages
...
nginx-common:
Installed: (none)
Candidate: 1.18.0-6.1+deb11u5
Version table:
1.18.0-6.1+deb11u5 500
500 http://security.debian.org/debian-security bullseye-security/main arm64 Packages
1.18.0-6.1+deb11u3 500
500 http://deb.debian.org/debian bullseye/main arm64 Packages
nginx-extras:
Installed: (none)
Candidate: 1.18.0-6.1+deb11u5
Version table:
1.18.0-6.1+deb11u5 500
500 http://security.debian.org/debian-security bullseye-security/main arm64 Packages
1.18.0-6.1+deb11u3 500
500 http://deb.debian.org/debian bullseye/main arm64 Packages
It seems that while the nginx package is indeed "wired" to the new repository, the other two packages aren't.
How can I fix that? I tried many (many) things, to no avail.
I can't install nginx because of this error:
$ sudo apt --fix-broken install
$ sudo apt install nginx nginx-common nginx-extras
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
nginx : Conflicts: nginx-common but 1.18.0-6.1+deb11u5 is to be installed
E: Unable to correct problems, you have held broken packages.
EDIT: I can successfully install nginx, but not nginx-extras, which is unfortunate as I need some nginx-extras functionality (like more_clear_headers).