1. make

nginx/1.25.4について、ここに記述してください。

Contents

  1. make
  2. history

../1.25.3 conoha

/1.25.4

Building nginx from Sources https://nginx.org/en/docs/configure.html

nginxインストール(ソースからビルド編)for RockyLinux8.4

最終更新日 2021年10月22日

https://qiita.com/shadowhat/items/988c885a76eb7db54354

OpenSSLは、あらかじめコンパイルをしておきます。

今回は「/usr/local/src/」に「openssl-1.1.1l.tar.gz」を回答したものを配置し、 そのディレクトリを「--with-openssl」で指定します。

OpenSSLに関しては、「OpenSSL(1.0.x)をインストールする(ソースからコンパイル)for CentOS 7.2」を参照してください。

cd nginx-1.21.3

./configure --prefix=/etc/nginx \
--sbin-path=/usr/sbin/nginx \
--with-pcre-jit \
--with-http_addition_module \
--with-http_dav_module \
--with-http_gzip_static_module \
--with-http_realip_module \
--with-http_stub_status_module \
--with-http_ssl_module \
--with-http_sub_module \
--with-mail \
--with-mail_ssl_module \
--with-openssl=/usr/local/src/openssl-1.1.1l

--with-http_ssl_module

2. history

起動スクリプトの配置

起動スクリプトは、CentOSのRPMから拝借しましょう。 nginx起動スクリプト配置先

nginx起動スクリプト

cat > /usr/lib/systemd/system/nginx.service << EOF

[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
After=network.target remote-fs.target nss-lookup.target

[Service]
Type=forking
PIDFile=/etc/nginx/logs/nginx.pid
ExecStartPre=/usr/sbin/nginx -t -c /etc/nginx/conf/nginx.conf
ExecStart=/usr/sbin/nginx -c /etc/nginx/conf/nginx.conf
ExecReload=/bin/kill -s HUP \$MAINPID
ExecStop=/bin/kill -s QUIT \$MAINPID
PrivateTmp=true

[Install]
WantedBy=multi-user.target

EOF

https://mogile.web.fc2.com/nginx/nginx1.15.0/configure.html


CategoryDns CategoryWatch CategoryTemplate

MoinQ: nginx/make (last edited 2024-03-24 12:27:12 by ToshinoriMaeno)