a-luna / aaronluna.dev

My personal website/blog/portfolio, built with Hugo
https://aaronluna.dev
3 stars 1 forks source link

blog/install-nginx-source-code-shell-script/ #287

Open utterances-bot opened 2 years ago

utterances-bot commented 2 years ago

Create a Shell Script to Install NGINX from Source On Ubuntu - aaronluna.dev

Why would you want to install NGINX from source code rather than a pre-built package? The most important reason is that the libraries which NGINX depends on (PCRE, zlib, OpenSSL) are part of the pre-built package, and building from source allows you to use the latest versions which may contain vital security patches. This post explains in detail how to install NGINX from source on Ubuntu, producing a .deb package which also allows you to easily uninstall the same instance of NGINX.

https://aaronluna.dev/blog/install-nginx-source-code-shell-script/

SorinGFS commented 2 years ago

I know this is quite old, but I think it should stil work. I used this script 3 years ago, and now I try it with the latest nginx version 1.21.6. I dont know what I'm doing wrong, but in this version Nginx does not include the /opt/src_files inside deb package... Anyway, I try to understand the step 28: Remove all source code files .. after nginx was installed! I thought that nginx uses /opt/scr_file/* in runtime, if you remove them how openssl is gonna be found?