首页 > 编程知识 正文

nginx配置文件参数详解,linux部署jar包项目并运行

时间:2023-05-06 21:26:47 阅读:13832 作者:1557

nginx部署安装nginx//防火墙和selinux [根@ localhost~] # systemctldisable-- nowfirewalldremoved/etc/系统/系统/dbus-org.fedora project.firewall D1.service.[ root @ localhoshosect ] e Linux=disabled/'/etc/安装依赖环境[ root @ localhost~] # yum-yinstallpcre-developensslopenssl-devel GD-develgccgcc-cmake [ root @ localhost ] 创建系统用户nginx [ root @ localhost~] #创建useradd-r-m-s/sww djm/nolog in nginx//日志存储目录[ root @ localhost ~ nginx/下载nginx [ root @ localhost~] # CD/usr/src/[ root @ localhost src ] # wget [ root @ localhost src ] # tarxfngng cdnginx-1.20.1编译并安装根@ localhost src-prefix=/usr/local/nginx--user=nginx--grouurd --with-debug _-- with-http _ SSL _ mmm-with-http _ image _ filter _ module --with-http _ gunzip _ module _-with-http _ gzip _ static _ module _-with-http _ gzip _ static _ modu modu TIC - error-log-path=/var/log/nginx/error.log [ root @ localhost nginx-1.20.1 ] # make-j $ (make install 愚人节5 ) echo ' export path=/usr/local/nginx/sww djm 3360 $ ] nginx.sh [ root @ localhost~] # source/etc/profile.d/nging local nginx命令-检查t//配置文件语法-使用v//输出nginx版本-c //配置文件路径-s //发送服务控制信号,可选值为{ stop|quit 设置启动时的自启动[ root @ localhost~] # VI/usr/lib/systemd/system/nginx.service ] escription=nginxstartafter=networor local/nginx/sww djm/nginxecstart nginx-sstopexecreload=/ww djm/kill-hup [ install ] wanted by=多用户. targrad systemctl启动nginx [ root @ localhost~~ ] # systemctlenable-- nownginxcreatedsymlink/etc/systemd/system/multi-uses nginx.service.[ root @ localhost~~ ] # ss-antlstaterecv-QS end-qlocaladdress 3360 portpeeraddress 3360 portprocesslisten 0128.0.0.03360220.0.0: listen 0120 listen 0128 [ :3360 ] 336022 [ :3360 ] : * [ root @ localhost ] systemctlstatusnginxnginx.service-nginxstartation 启用活动:活动(运行) since sun 2020-10-250933600336001 CST; 5mainPID:33402(nginx ) tasks:2 ) limit:12221 ) memory :3.7 MC group :/system.slice/nginx.service33336 nginx/sww djm/n (33403 nginx : workerprocessoct 250933600336001 localhost.localdomainsystemd [1] 3360 startingnginxoct 250933600:01 localhost.localdomainsystemd [1] : startednginxlines1- 12/12 (end ) http://www

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。