三、脚本

CentOS7 环境安装脚本:软件运维配置脚本集合

安装说明

  • 采用编译方式安装 Nginx, 并将其注册为 systemd 服务
  • 安装路径为:/usr/local/nginx
  • 默认下载安装 1.16.0 版本

使用方法

  • 默认安装 - 执行以下任意命令即可:
  1. curl -o- https://gitee.com/turnon/linux-tutorial/raw/master/codes/linux/soft/nginx-install.sh | bash
  2. wget -qO- https://gitee.com/turnon/linux-tutorial/raw/master/codes/linux/soft/nginx-install.sh | bash
  • 自定义安装 - 下载脚本到本地,并按照以下格式执行:
  1. sh nginx-install.sh [version]