At the Nginx website, there is a way to install the mainline Nginx version instead of the default OS version, but I did not see any info about nginx-extras. And if you install the mainline version, then the default extras version is trying to install the default nginx version for that OS, so that won't work if you use the mainline version of Nginx.
Is there a way to install nginx-extras for the mainline version on Debian/Ubuntu?