zoukankan      html  css  js  c++  java
  • nginx应用编译安装

    nginx应用编译安装:

    • 安装编译所需依赖包:
    # apt-get install make gcc g++ libcurl3-openssl-dev libfreetype6-dev libmcrypt-dev
    # apt-get install libpcre3 libpcre3-dev zlib1g-dev libssl-dev build-essential
    # apt-get install openssl libssl-dev
    
    • 编译nginx:(无用户)
    # cd /usr/local/src 
    # wget http://nginx.org/download/nginx-1.8.0.tar.gz
    # tar -zxvf nginx-1.8.0.tar.gz
    # cd nginx-1.8.0/ 
    # ./configure --prefix=/Sioeye/SioApps/Environment/nginx --with-http_ssl_module --with-http_realip_module --with-http_stub_status_module --with-http_gzip_static_module --with-pcre
    # make && make install
    # ln -sv /Sioeye/SioApps/Environment/nginx/sbin/nginx /etc/init.d/nginx
    # mv /home/pengchuan/nginx /etc/init.d/  ### /home/pengchuan/nginx为上传的nginx启动文件
    # chmod a+x /etc/init.d/nginx 
    # update-rc.d nginx defaults
    # vim /etc/rc.local
    	/etc/init.d/nginx
    	exit 0
    # chmod a+x /etc/rc.local
    
    • 编译nginx:(有用户)
    # useradd -s /usr/sbin/nologin -r nginx
    # cd /usr/local/src
    # wget http://nginx.org/download/nginx-1.8.0.tar.gz 
    # tar -zxvf nginx-1.8.0.tar.gz
    # cd nginx-1.8.0/
    # ./configure --prefix=/Sioeye/SioApps/Environment/nginx --with-http_ssl_module --user=nginx --group=nginx --with-http_realip_module --with-http_stub_status_module --with-http_gzip_static_module --with-pcre
    # make && make install
    # ln -sv /Sioeye/SioApps/Environment/nginx/sbin/nginx /etc/init.d/nginx
    # update-rc.d nginx defaults 99
    
    • 修改配置文件
    # vi nginx.conf
    
  • 相关阅读:
    webpack + vue 向本地后端发送http请求跨域问题
    用FileReader对象从本地读取文件
    oninput与onchange比较
    height: 100% 无效问题
    关于html布局
    圣诞节给自己的犒劳
    django学习之——模版
    django学习之——我的 Hello World
    django学习之——创建项目
    python and pycharm and django 环境配置
  • 原文地址:https://www.cnblogs.com/evescn/p/10692294.html
Copyright © 2011-2022 走看看