Created
July 25, 2015 05:24
-
-
Save d30jeff/e37bb1f1816fc875dbfd to your computer and use it in GitHub Desktop.
Config
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # You may add here your | |
| # server { | |
| # ... | |
| # } | |
| # statements for each of your virtual hosts to this file | |
| ## | |
| # You should look at the following URL's in order to grasp a solid understanding | |
| # of Nginx configuration files in order to fully unleash the power of Nginx. | |
| # http://wiki.nginx.org/Pitfalls | |
| # http://wiki.nginx.org/QuickStart | |
| # http://wiki.nginx.org/Configuration | |
| # | |
| # Generally, you will want to move this file somewhere, and start with a clean | |
| # file but keep this around for reference. Or just disable in sites-enabled. | |
| # | |
| # Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples. | |
| ## | |
| server { | |
| listen 9001; ## listen for ipv4; this line is default and implied | |
| #listen [::]:80 default ipv6only=on; ## listen for ipv6 | |
| #root /usr/share/nginx/www; | |
| root /home/deojeff/Emeley/src; | |
| # Make site accessible from http://localhost/ | |
| server_name localhost; | |
| #location / { | |
| #rewrite ^/$ /login; | |
| #} | |
| #location /login { | |
| #rewrite ^/ /scripts/index-login.html; | |
| #} | |
| #location /app { | |
| #rewrite ^/ /scripts/index.html; | |
| #} | |
| location /service { | |
| proxy_pass http://127.0.0.1:8000; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| } | |
| server { | |
| listen 8080; ## listen for ipv4; this line is default and implied | |
| #listen [::]:80 default ipv6only=on; ## listen for ipv6 | |
| #root /usr/share/nginx/www; | |
| root /home/deojeff/DeojeffFolder/rms-frontend; | |
| # Make site accessible from http://localhost/ | |
| server_name localhost; | |
| #location / { | |
| #rewrite ^/$ /login; | |
| #} | |
| #location /login { | |
| #rewrite ^/ /scripts/index-login.html; | |
| #} | |
| #location /app { | |
| #rewrite ^/ /scripts/index.html; | |
| #} | |
| location /service { | |
| proxy_pass http://127.0.0.1:8000; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| } | |
| server { | |
| listen 80; ## listen for ipv4; this line is default and implied | |
| #listen [::]:80 default ipv6only=on; ## listen for ipv6 | |
| #root /usr/share/nginx/www; | |
| root /opt/www; | |
| # Make site accessible from http://localhost/ | |
| server_name localhost; | |
| location / { | |
| rewrite ^/$ /login; | |
| } | |
| location /login { | |
| rewrite ^/ /scripts/index-login.html; | |
| } | |
| location /app { | |
| rewrite ^/ /scripts/index.html; | |
| } | |
| location /service { | |
| proxy_pass http://127.0.0.1:8000; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| } | |
| } | |
| upstream sis_service { | |
| server unix:/tmp/sis_service.sock fail_timeout=0; | |
| } | |
| # another virtual host using mix of IP-, name-, and port-based configuration | |
| # | |
| #server { | |
| # listen 8000; | |
| # listen somename:8080; | |
| # server_name somename alias another.alias; | |
| # root html; | |
| # index index.html index.htm; | |
| # | |
| # location / { | |
| # try_files $uri $uri/ /index.html; | |
| # } | |
| #} | |
| # HTTPS server | |
| # | |
| #server { | |
| # listen 443; | |
| # server_name localhost; | |
| # | |
| # root html; | |
| # index index.html index.htm; | |
| # | |
| # ssl on; | |
| # ssl_certificate cert.pem; | |
| # ssl_certificate_key cert.key; | |
| # | |
| # ssl_session_timeout 5m; | |
| # | |
| # ssl_protocols SSLv3 TLSv1; | |
| # ssl_ciphers ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv3:+EXP; | |
| # ssl_prefer_server_ciphers on; | |
| # | |
| # location / { | |
| # try_files $uri $uri/ /index.html; | |
| # } | |
| #} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment