Articles of redirect

redirectsudirectory请求到局域网中的另一个IP

我试图redirect/networkingmyfakedomain.com到局域网中的另一个ip xxx.xxx.xxx.120。 也就是说,当我尝试访问myfakedomain.com/net时,它应该显示xxx.xxx.xxx.120的内容 我也正在将http请求redirect到https,如下所示 <VirtualHost *:80> # The ServerName directive sets the request scheme, hostname and port that # the server uses to identify itself. This is used when creating # redirection URLs. In the context of virtual hosts, the ServerName # specifies what hostname must appear in the request's Host: header to # match […]

cnamelogging和redirect到非www

我遇到了一些问题。 1)我设置了CNAMElogging的子域,它与我的服务器之外的一些SaaS系统一起工作。 其开始时没有“www”的域名,例如。 name.domain.com。 2)我尝试将“www”(例如www.name.domain.com)的子域名设置到我的服务器,并将其redirect到获得SaaS系统所在的外部服务器的CNAME的域。 但它不是那样工作的。 3)我不能做任何事情,如把htaccess的SaaS服务器,我只能在该系统(现在它没有“www”)设置一个地址。 是否有可能redirectwww.name.domain.com到name.domain.com考虑到我上面写的是什么?

Nginx反向代理太多的redirect

我想configurationnginx作为一个反向代理,根据传递的URI将redirect到两个不同的Kibana主机。 /redirect到标准和/october/到十月专用Kibana。 configuration( / )的第一部分工作正常,但尝试访问/october时,我得到了Too many redirections错误。 我尝试将第二部分( location /october/ )注释掉,并在第一部分中将10.10.0.3replace为localhost ,然后将其redirect到十月平台。 所以问题在于这个nginxconfiguration。 server { listen 80; server_name my.domain.io; return 301 https://$server_name; } server { listen 443 ; ssl on; ssl_certificate /etc/letsencrypt/live/my.domain.io/cert.pem; ssl_certificate_key /etc/letsencrypt/live/my.domain.io/privkey.pem; server_name my.domain.io; access_log /var/log/nginx/kibana.access.log; error_log /var/log/nginx/kibana.error.log; location / { auth_basic "Restricted"; auth_basic_user_file /etc/nginx/conf.d/kibana.htpasswd; location / { proxy_pass http://localhost:5601; proxy_http_version 1.1; proxy_set_header […]

无法修复nginxredirect到端口8080访问URL时不使用斜杠

我一直在试图解决这个如此烦人的错误,但没有奏效。 在这篇文章中,我遵循并尝试了很多方法, 当访问不带斜杠的URL时,Nginxredirect到端口8080,但仍然存在。 我正在使用nginx广告反向代理阿帕奇。 这是我的nginxconfiguration文件: server { listen 80; ## listen for ipv4 #listen [::]:80 default ipv6only=on; ## listen for ipv6 server_name domain.com *.domain.com; #access_log /var/log/nginx/localhost.access.log; location / { proxy_pass http://127.0.0.1:8080/; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } location ~* \.(jpg|jpeg|png|gif|png|css|js|swf)$ { root /var/www/html/domain/; } } 和http http { include /etc/nginx/mime.types; default_type […]

当服务器使用permredirect保护时,从SSL中排除Apache服务器上的文件?

我有一个在Ubuntu服务器上运行的Apache 2 Web服务器。 我将整个服务器redirect到启用了以下站点的SSL: <VirtualHost *:80> ServerName hda.surfrock66.com/ Redirect permanent / https://hda.surfrock66.com/ </VirtualHost> 我有一个令人讨厌的php文件,它能够从无法validationSSL的应用程序上传数据。 有没有一种方法来禁用一个单一的网站上的单个文件的ssl,也许与.htaccess什么的? 我已经阅读了关于这个问题的广泛的文章,而且他们都没有工作,所以我坚持从头开始寻求帮助。 谢谢!

如何简单地将IP重新路由到另一个?

基本上,这是我的需要:能够在我的60多个域名的DNS区域中指定一个IP地址,并且能够将这个IPredirect到另一个IP (并在需要时进行更改)。 我不是那种“networking人”,所以有一点帮助会..好吧…帮助! 😉 我需要这个,因为我pipe理2个不同的专用服务器: 服务器#1 :生产, 公共IP#1 。 服务器#2 :在发生灾难的情况下,使用公共IP#2紧急。 我所有的域名DNS区域都指向IP地址为#1的服务器#1(制作)。 当我的服务器#1(生产)将closures(在灾难的情况下),我将需要redirect所有的域名到服务器#2(紧急)。 在这种情况下,我的计划是要做到以下几点: 手动更改我的60多个域名的DNS区域,让他们指向服务器#2(紧急)的IP#2 等待DNS阻塞延迟 有没有更好的办法做到这一点,让我有我的DNS区域总是指向一个IP,并允许我改变只有一行的IPredirect到IP#1,或IP#2时,我需要它? 我是否需要pipe理仅用于此angular色的“外部”Windows Server? (这将是昂贵的)或ö任何在线服务允许这样做? (但代价是我必须避免的延迟)? 请注意,公共IP在Windows Server的许多地方使用:IIS Web服务器,Pleskconfiguration等 附加信息:如果可以帮助,我的DNS区域由OVHpipe理。

Nginx与SSL连接错误

我试图从HTTP迁移到HTTPS,但是,我的nginx(版本:1.10.3)configuration似乎没有工作。 以下行为是需要的: http://www.example.com/path/to/content应该redirect到https://example.com/path/to/content http://example.com/path/to/content应redirect到https://example.com/path/to/content https://www.example.com/path/to/content应redirect到https://example.com/path/to/content 与我目前的configuration浏览器不会连接到使用HTTPS的网站: server { listen 80; listen [::]:80; server_name www.example.com example.com; # redirects both www and non-www to https rewrite ^(.*) https://www.example.com$1 permanent; } server { listen 443 ssl http2; listen [::]:443 ssl http2; server_name example.com; # redirects non-www to www rewrite ^(.*) https://www.example.com$1 permanent; } server { listen 443 ssl […]

我怎样才能让NGINX有条件地redirect到HTTPS?

我正在设置让我们encryption自动发出证书。 每个用户都有自己的子域名,所以我需要每隔几个小时批量创build一个证书,以避免LE的限制。 在他们注册的时间和他们的证书准备好的时候,我想通过HTTP服务他们的子域名。 只要证书存在,操作应始终将HTTPredirect到HTTPS。 奖励,如果我们可以检查证书的有效性。 build议?

Nginx删除redirect请求

我有redirect规则: location /aanbod.html?limit=all {return 301 https://www.site.nl/compleet/ ;} 这个规则redirect,但是留下限制=所有请求 如何删除它并得到没有请求的新url? Thaks!

RewriteMap指令(永久或临时redirect?)

这可能听起来像一个愚蠢的问题,我可能混合苹果和橙子,但请忍受我。 我正在阅读这里的文档http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html#mapfunc 它说当使用外部.txt文件格式是一个简单的键/值对的例子: fromHere.html toHere.html ^我想确认,上述将创build一个临时302redirect(该浏览器不会积极caching),或者可能是我可以指示redirect的types(301/302)在实际的RewriteRule中htaccess文件? (如果是的话)? 目前,我在.htaccess文件中使用了以下语法 将302从Here.htmlredirect到Here.html 上述语法是否允许在外部.txt文件中? 谢谢