Linux安装Ngnix
作者:互联网
安装Nginx
安装依赖
- 安装依赖
yum -y install gcc zlib zlib-devel pcre-devel
nginx
- 下载压缩包
cd /usr/local/
wget http://nginx.org/download/nginx-1.18.0.tar.gz
nginx下载地址在官网获取
- 解压
tar -zxvf nginx-1.18.0.tar.gz
编译安装
- 检查环境
cd nginx-1.18.0/
./configure
- 编译安装
make && make install
检查安装状态
/usr/local/nginx/sbin/nginx -v
启动
/usr/local/nginx/sbin/nginx
启动后访问:
curl localhost:80
标签:tar,local,Ngnix,1.18,nginx,usr,Linux,安装 来源: https://blog.csdn.net/tt75281920/article/details/117266499