📜  安装 nginx amazon linux 2 - 任何代码示例

📅  最后修改于: 2022-03-11 14:55:36.152000             🧑  作者: Mango

代码示例1
$ sudo amazon-linux-extras list | grep nginx
 38  nginx1=latest            disabled      [ =stable ]

$ sudo amazon-linux-extras enable nginx1
 38  nginx1=latest            enabled      [ =stable ]
        
Now you can install:
$ sudo yum clean metadata
$ sudo yum -y install nginx
    
$ nginx -v
nginx version: nginx/1.16.1