zoukankan      html  css  js  c++  java
  • nginx*配置及systemd 配置

    #user  nobody;
    worker_processes  1;
    
    #error_log  logs/error.log;
    #error_log  logs/error.log  notice;
    #error_log  logs/error.log  info;
    
    #pid        logs/nginx.pid;
    
    
    events {
        worker_connections  1024;
    }
    
    
    http {
        #log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
        #                  '$status $body_bytes_sent "$http_referer" '
        #                  '"$http_user_agent" "$http_x_forwarded_for"';
    
        #log_format upstreamlog '[$time_local] $remote_addr - $remote_user - $server_name to: $upstream_addr: $request upstream_response_time $upstream_response_time msec $msec request_time $request_time';
    
        log_format  main  '$status - $proxy_host "$request" $upstream_addr';
                          
       
    
        server
        {
            access_log  logs/access.log  main;
            listen 80;
            location /
            {
                proxy_pass   http://127.0.0.1:5000;
                proxy_read_timeout 9999;
            }
            location /api/fi/aa/v1.0/
            {
                proxy_pass   http://127.0.0.1:8080;
                proxy_read_timeout 9999;
            }
            location /api/fastdweb/runtime/v1.0/
            {
                proxy_pass   http://127.0.0.1:8080;
                proxy_read_timeout 9999;
            }
        }
           
    }
    

      

    [Unit]
    Description=The NGINX HTTP and reverse proxy server
    After=syslog.target network.target remote-fs.target nss-lookup.target
    
    [Service]
    Type=forking
    PIDFile=/run/nginx.pid
    ExecStartPre=/usr/sbin/nginx -t
    ExecStart=/usr/sbin/nginx
    ExecReload=/usr/sbin/nginx -s reload
    ExecStop=/bin/kill -s QUIT $MAINPID
    PrivateTmp=true
    
    [Install]
    WantedBy=multi-user.target
    

      

  • 相关阅读:
    python中的__init__
    python中的单例模式
    python中闭包和装饰器
    sql多表查询
    configurationChanges
    excludeFromRecents标签
    activity-alias
    meta-data
    launchMode
    Apache ant 配置
  • 原文地址:https://www.cnblogs.com/qianjinyan/p/13625622.html
Copyright © 2011-2022 走看看