Skip to content

Commit a0ede87

Browse files
committed
fix EOL
1 parent 3c5a201 commit a0ede87

File tree

4 files changed

+91
-4
lines changed

4 files changed

+91
-4
lines changed

etc/nginx/nginx.conf

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,19 @@
1-
worker_processes 2;events { worker_connections 4096;}http { set_real_ip_from 127.0.0.1; real_ip_header X-Forwarded-For; limit_conn_zone $binary_remote_addr zone=default:10m; limit_conn_log_level notice; keepalive_timeout 10; types_hash_max_size 2048; server_tokens off; server_names_hash_bucket_size 64;}
1+
worker_processes 2;
2+
3+
events {
4+
worker_connections 4096;
5+
}
6+
7+
http {
8+
set_real_ip_from 127.0.0.1;
9+
real_ip_header X-Forwarded-For;
10+
11+
limit_conn_zone $binary_remote_addr zone=default:10m;
12+
limit_conn_log_level notice;
13+
14+
keepalive_timeout 10;
15+
types_hash_max_size 2048;
16+
server_tokens off;
17+
18+
server_names_hash_bucket_size 64;
19+
}
Lines changed: 51 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,51 @@
1-
server { listen 8080; server_name www.example.com; rewrite ^ $scheme://example.com$request_uri? permanent;}server { listen 8080 default; server_name example.com; root /var/www/example.com/current/web; access_log /var/www/example.com/logs/access.log; error_log /var/www/example.com/logs/error.log error; client_max_body_size 4M; index app.php index.html index.htm; try_files $uri $uri/ @rewrite; location @rewrite { rewrite ^/(.*)$ /app.php/$1; } location ~* \.(?:ico|css|js|gif|jpe?g|png)$ { expires 18h; add_header Cache-Control "public, must-revalidate, proxy-revalidate"; } location ~ \.php { limit_conn default 50; try_files $uri =404; fastcgi_index app.php; fastcgi_pass 127.0.0.1:9000; include fastcgi_params; fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_param PATH_INFO $fastcgi_path_info; fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param SERVER_PORT 80; fastcgi_param SERVER_NAME example.com; } location ~ /\.ht { deny all; }}
1+
server {
2+
listen 8080;
3+
server_name www.example.com;
4+
rewrite ^ $scheme://example.com$request_uri? permanent;
5+
}
6+
7+
server {
8+
listen 8080 default;
9+
server_name example.com;
10+
11+
root /var/www/example.com/current/web;
12+
13+
access_log /var/www/example.com/logs/access.log;
14+
error_log /var/www/example.com/logs/error.log error;
15+
16+
client_max_body_size 4M;
17+
18+
index app.php index.html index.htm;
19+
20+
try_files $uri $uri/ @rewrite;
21+
22+
location @rewrite {
23+
rewrite ^/(.*)$ /app.php/$1;
24+
}
25+
26+
location ~* \.(?:ico|css|js|gif|jpe?g|png)$ {
27+
expires 18h;
28+
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
29+
}
30+
31+
location ~ \.php {
32+
limit_conn default 50;
33+
34+
try_files $uri =404;
35+
36+
fastcgi_index app.php;
37+
fastcgi_pass 127.0.0.1:9000;
38+
39+
include fastcgi_params;
40+
fastcgi_split_path_info ^(.+\.php)(/.+)$;
41+
fastcgi_param PATH_INFO $fastcgi_path_info;
42+
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
43+
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
44+
fastcgi_param SERVER_PORT 80;
45+
fastcgi_param SERVER_NAME example.com;
46+
}
47+
48+
location ~ /\.ht {
49+
deny all;
50+
}
51+
}

etc/php5/fpm/php-fpm.conf

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,8 @@
1-
listen = 127.0.0.1:9000pm = dynamicpm.max_children = 25pm.start_servers = 3pm.min_spare_servers = 2pm.max_spare_servers = 4pm.max_requests = 500pm.process_idle_timeout = 10s;
1+
listen = 127.0.0.1:9000
2+
pm = dynamic
3+
pm.max_children = 25
4+
pm.start_servers = 3
5+
pm.min_spare_servers = 2
6+
pm.max_spare_servers = 4
7+
pm.max_requests = 500
8+
pm.process_idle_timeout = 10s;

etc/php5/fpm/php.ini

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,13 @@
1-
[APC]extension = apc.soapc.enabled = 1apc.shm_segments = 1apc.shm_size = 32Mapc.optimization = 0apc.num_files_hint = 512apc.user_entries_hint = 1024apc.ttl = 0apc.user_ttl = 0apc.gc_ttl = 600apc.cache_by_default = 1apc.stat = 1
1+
[APC]
2+
extension = apc.so
3+
apc.enabled = 1
4+
apc.shm_segments = 1
5+
apc.shm_size = 32M
6+
apc.optimization = 0
7+
apc.num_files_hint = 512
8+
apc.user_entries_hint = 1024
9+
apc.ttl = 0
10+
apc.user_ttl = 0
11+
apc.gc_ttl = 600
12+
apc.cache_by_default = 1
13+
apc.stat = 1

0 commit comments

Comments
 (0)