我是Nginx新手,我已经使用this tutorial设置了服务器。现在,当我添加链接到其他网站,如http://www.anotherwebsite.com,当我从我的页面上点击此链接时,服务器将我指向http://www.mywebsite.com/http://www.anotherwebsite.com。服务器正在将其他链接附加到我的网站链接。我该如何改变这一点。我已经看过这些地方 How to redirect a url in NGINX, Rewrite to pretty links with nginx 但我只是不能让它的工作。任何帮助将不胜感激。由于在nginx服务器中打开其他网站的链接
server {
listen 80;
server_name $hostname;
location /static {
alias /var/www/<app-name>/static;
}
error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
location/{
include uwsgi_params;
uwsgi_pass unix:/tmp/uwsgi.sock;
uwsgi_param UWSGI_PYHOME /var/www/<app-name>/env;
uwsgi_param UWSGI_CHDIR /var/www/<app-name>/project;
uwsgi_param UWSGI_MODULE <project-name>.wsgi:application;
}
}
那么你的当前配置看起来像没有访问权限的黑客? – cobaco
[链接到配置文件](http://pastecode.org/index.php/view/54100324) – Saad