四步debian10安装最新nginx

2021-09-03 17:56:56 浏览数 (1)

1.删除nginx

apt-get-y autoremove --purge nginx

2.添加nginx官方仓库

echo "deb http://nginx.org/packages/debian/ buster nginx">> /etc/apt/sources.list

echo "deb-src http://nginx.org/packages/debian/ buster nginx">> /etc/apt/sources.list

wget http://nginx.org/keys/nginx_signing.key && apt-key add nginx_signing.key

3.更新

apt-get update -y

4.安装

apt-get install-y nginx

0 人点赞