Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: кеширование элементов дизайна
Поправил конфиги nginx.conf и ssl.conf , после чего выводиться стал только
текст:
Что не так сделал?
#
nginx.conf::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
user nginx;
worker_processes 4;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request"
'
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
proxy_cache_path /var/cache/nginx/proxy_cache levels=1:2
keys_zone=static:64m inactive=24h max_size=512m;
proxy_temp_path /var/cache/nginx/proxy_temp 1 2;
proxy_ignore_headers Expires Cache-Control;
#proxy_cache_use_stale error timeout updating invalid_header http_502;
proxy_cache_bypass $cookie_session;
proxy_no_cache $cookie_session;
sendfile on;
tcp_nopush on;
keepalive_timeout 65;
gzip on;
gzip_static on;
gzip_proxied any;
gzip_min_length 1100;
gzip_http_version 1.0;
gzip_buffers 4 8k;
gzip_comp_level 5;
gzip_types text/plain text/css application/x-javascript
text/xml application/xml application/xml+rss text/javascript
application/json;
include /etc/nginx/conf.d/*.conf;
}
#::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# ssl.conf
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
# HTTPS server
server {
listen 443;
server_name localhost;
ssl on;
ssl_certificate /etc/nginx/ssl/cert.pem;
ssl_certificate_key /etc/nginx/ssl/cert.key;
ssl_session_timeout 5m;
ssl_protocols SSLv2 SSLv3 TLSv1;
ssl_ciphers HIGH:!aNULL:!MD5;
ssl_prefer_server_ciphers on;
location ~^/domjs/ {
root /var/www/;
}
location ~* ^.+\.(gif|gz|css|ico|js)$ {
proxy_set_header Host $host;
proxy_cache static;
proxy_cache_valid 200 302 30m;
proxy_cache_valid 404 1m;
#expires 1d;
}
location / {
proxy_pass http://192.168.1.245:8080;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
client_max_body_size 10m;
client_body_buffer_size 128k;
proxy_connect_timeout 90;
proxy_send_timeout 90;
proxy_read_timeout 90;
proxy_buffer_size 4k;
proxy_buffers 4 32k;
proxy_busy_buffers_size 64k;
proxy_temp_file_write_size 64k;
proxy_ignore_client_abort on;
}
}
Posted at Nginx Forum:
http://forum.nginx.org/read.php?21,234478,234561#msg-234561
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://mailman.nginx.org/mailman/listinfo/nginx-ru
|