打开域名主页是Welcome to nginx
回 1楼西秦的帖子
阿里云一键安装包有Phpwind,我只是设置域名304就变成Welcome to nginx!
-------------------------
Re打开域名主页是Welcome to nginx
取消304,打开域名就可以到安装界面
-------------------------
Re打开域名主页是Welcome to nginx
好的,麻烦帮忙看看
-------------------------
回 4楼西秦的帖子
nginx.conf
user www www;
worker_processes 1;
error_log /alidata/log/nginx/error.log crit;
pid /alidata/server/nginx/logs/nginx.pid;
#Specifies the value for maximum file descriptors that can be opened by this process.
worker_rlimit_nofile 65535;
events
{
use epoll;
worker_connections 65535;
}
http {
include mime.types;
default_type application/octet-stream;
#charset gb2312;
server_names_hash_bucket_size 128;
client_header_buffer_size 32k;
large_client_header_buffers 4 32k;
client_max_body_size 8m;
sendfile on;
tcp_nopush on;
keepalive_timeout 60;
tcp_nodelay on;
fastcgi_connect_timeout 300;
fastcgi_send_timeout 300;
fastcgi_read_timeout 300;
fastcgi_buffer_size 64k;
fastcgi_buffers 4 64k;
fastcgi_busy_buffers_size 128k;
fastcgi_temp_file_write_size 128k;
gzip on;
gzip_min_length 1k;
gzip_buffers 4 16k;
gzip_http_version 1.0;
gzip_comp_level 2;
gzip_types text/plain application/x-javascript text/css application/xml;
gzip_vary on;
#limit_zone crawler $binary_remote_addr 10m;
log_format '$remote_addr - $remote_user [$time_local] '$request' '
'$status $body_bytes_sent '$http_referer' '
''$http_user_agent' '$http_x_forwarded_for'';
include /alidata/server/nginx/conf/vhosts/*.conf;
-------------------------
回 7楼西秦的帖子
phpwind.conf
server {
server_name www.etongwang.com etongwang.com;
location /phpwind/
{
root /www/phpwind/html/;
}
if ($host != 'www.etongwang.com' ) {
rewrite ^/(.*)$ http://www.etongwang.com/$1 permanent;
}}
红色是我后添加的,删掉重启nginx 就可以打开到网站安装程序界面PHPWIND
server {
listen 80;
server_name localhost;
index index.html index.htm index.php;
root /alidata/www/phpwind;
location ~ .*\.(php|php5)?$
{
#fastcgi_pass unix:/tmp/php-cgi.sock;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi.conf;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
expires 30d;
}
location ~ .*\.(js|css)?$
{
expires 1h;
}
#伪静态规则
include /alidata/server/nginx/conf/rewrite/phpwind.conf;
access_log /alidata/log/nginx/access/phpwind.log;
}
-------------------------
Re打开域名主页是Welcome to nginx
default.conf.bak
server {
listen 80;
server_name localhost;
index index.html index.htm index.php;
root /alidata/www/default;
location ~ .*\.(php|php5)?$
{
#fastcgi_pass unix:/tmp/php-cgi.sock;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi.conf;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
expires 30d;
}
location ~ .*\.(js|css)?$
{
expires 1h;
}
#伪静态规则
include /alidata/server/nginx/conf/rewrite/default.conf;
access_log /alidata/log/nginx/access/default.log;
-------------------------
回 10楼西秦的帖子
nginx.conf.default
在这个文件修改吗,具体点说明好吗
#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 {
include 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 logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
server {
listen 80;
server_name localhost;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
root html;
index index.html index.htm;
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
# another virtual host using mix of IP-, name-, and port-based configuration
#
#server {
# listen 8000;
# listen somename:8080;
# server_name somename alias another.alias;
# location / {
# root html;
# index index.html index.htm;
# }
#}
# HTTPS server
#
#server {
# listen 443;
# server_name localhost;
# ssl on;
# ssl_certificate cert.pem;
# ssl_certificate_key cert.key;
# ssl_session_timeout 5m;
# ssl_protocols SSLv2 SSLv3 TLSv1;
# ssl_ciphers HIGH:!aNULL:!MD5;
# ssl_prefer_server_ciphers on;
# location / {
# root html;
# index index.html index.htm;
# }
#}
}
-------------------------
回 12楼西秦的帖子
好的,我试试
赞0
踩0