-
-
Save thanhleviet/2486059 to your computer and use it in GitHub Desktop.
My nginx configuration for opendata-map.org
This file contains 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
server { | |
listen 80; | |
server_name www.opendata-map.org; | |
root /var/www/opendata-map.org; | |
access_log /var/log/nginx/opendata-map.access.log; | |
error_log /var/log/nginx/opendata-map.error.log debug; | |
# GEOSERVER PROXY & CACHE | |
location /geoserver { | |
proxy_pass http://127.0.0.1:8080/geoserver; | |
proxy_cache geoserver-cache; | |
proxy_cache_valid 200 302 10m; | |
proxy_cache_valid 404 1m; | |
proxy_no_cache $cookie_nocache $arg_nocache $arg_comment; | |
proxy_no_cache $http_pragma $http_authorization; | |
proxy_cache_bypass $cookie_nocache $arg_nocache $arg_comment; | |
proxy_cache_bypass $http_pragma $http_authorization; | |
} | |
# PLAY PUBLIC FOLDER | |
location /public { | |
expires max; | |
root /opt/mapLibertic/; | |
} | |
# PLAY PROXY | |
location / { | |
proxy_pass http://127.0.0.1:9001/; | |
} | |
} | |
server { | |
listen 80; | |
server_name opendata-map.org; | |
rewrite ^/(.*) http://www.opendata-map.org/$1 permanent; | |
} |
This file contains 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
server { | |
listen 80; | |
server_name www.opendata-map.org; | |
root /var/www/opendata-map.org; | |
access_log /var/log/nginx/opendata-map.access.log; | |
error_log /var/log/nginx/opendata-map.error.log debug; | |
# GEOSEREVR PROXY | |
location /geoserver { | |
proxy_pass http://127.0.0.1:8080/geoserver; | |
} | |
# PLAY PUBLIC FOLDER | |
location /public { | |
expires max; | |
root /opt/mapLibertic/; | |
} | |
# PLAY PROXY | |
location / { | |
proxy_pass http://127.0.0.1:9001/; | |
} | |
} | |
server { | |
listen 80; | |
server_name opendata-map.org; | |
rewrite ^/(.*) http://www.opendata-map.org/$1 permanent; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment