26
4
I have a local DNS server that resolves all URLs *.domain.tld
to 127.0.0.1
.
Also, I have the production server with the same address *.domain.tld
.
They have the same names, because subdomains interact with each other, and I have hardcoded domain URLs. I can't change them in the production server.
The problem is to reach the production server from my developer computer without touching the DNS server and /etc/hosts
.
I found some options for Chrome such as --dns-server
, --host-rules
, but none is working.
I have Google Chrome 23.0.1271.64 and Chromium 22.0.1229.94 on Ubuntu 12.10 64-bit.
This could be related to http://superuser.com/questions/284110/redirect-urls-in-chrome.
– sachinjain024 – 2015-10-31T23:25:01.550star this feature request: https://bugs.chromium.org/p/chromium/issues/detail?id=893165&can=2&q=component%3AInternals%3ENetwork%3EDNS%20&colspec=ID%20Pri%20M%20Stars%20ReleaseBlock%20Component%20Status%20Owner%20Summary%20OS%20Modified
– Ali – 2018-10-08T15:32:07.333What OS are you on? It's not an option to modify
/etc/hosts
(or its equivalent) on your computer (the one with Chrome)? – poplitea – 2012-11-29T10:09:00.8271You could run a local proxy with a rule to route your request as you wish. – Flup – 2013-03-18T14:16:29.257
Seems like
– Der Hochstapler – 2013-03-18T14:31:04.600--dns-server
is no longer supported.Would for example the Switcheroo Redirector extension or the Redirector extension be useful?
– harrymc – 2013-03-18T14:48:49.900@harrymc Those two claim to redirect HTTP requests, but I think a DNS request is something different. – Louis – 2013-03-19T13:45:10.430
@Louis: The post says Chrome, and these extensions can redirect a named HTTP request to an IP address, therefore solving the problem without monkeying with DNS. – harrymc – 2013-03-19T14:12:30.463