Comments (5)
Perhaps an approach to have a similar proxy in inverse, on the client machine, would fix this?
from iisexpress-proxy.
I guess this is kind of an edge scenario, but it doesn't look like a bug in iisexpress-proxy
.
Your server-side method generates URLs based on HttpContext.Current.Request.Url.Authority
HttpContext.Current.Request.ApplicationPath
. Can you please post a few sample URLs you're getting with and without using iisexpress-proxy
?
from iisexpress-proxy.
The above method produces the same url with or without the proxy.
example, if my website is hosted at localhost:1000, and my proxy allows the network to access 192.168.1.200:2000
above method produces: localhost:1000/Assets/foo.js
So on my macbook which is not hosting the site, I am going to 192.168.1.200:2000 but foo.js fails to load because it is trying to use localhost:1000/Assets/foo.js instead of 192.168.1.200:2000/Assets/foo.js
Only way I can see to fix this is to also have a similar proxy on my macbook, so that I can, on my macbook go to localhost:1000 and all traffic to that location is rerouted to 192.168.1.200:2000. Do you know of a way I can do that? Thank you.
from iisexpress-proxy.
Oh, I see. Including the hostname in dynamically generated URLs is always going to be a problem.
Basically, this utility is working by convincing IISExpress that requests are coming from localhost, so your method will always put localhost
in the generated URLs. I really can't think of a simple way to circumvent this...
I've intended iisexpress-proxy
to be a quick-and-dirty solution for the simplest use cases, and yours is clearly not one of them :-). So maybe you should have a look at browsersync.io. It's a nice, featured-packed utility I'm using for my own development workflow, since I've fully switched from .NET to Node.js. You can even tunnel your local server to public temporary subdomains on localtunnel.me and synchronize user actions across multiple devices...
from iisexpress-proxy.
Going to close this now, since it's not a bug in iisexpress-proxy
.
from iisexpress-proxy.
Related Issues (20)
- Offline installation fails - npmbox npmunbox HOT 3
- Request requires localhost HOT 3
- Sorry for not being active during the last couple of weeks HOT 1
- Redirects to the IIS server should be transformed HOT 4
- HTTPS
- unable to use it on android emulator like gennymotion
- SignalR not working with proxy. HOT 4
- Error: Can't set headers after they are sent.
- VPN functionality not working
- AWS EC2 HOT 2
- Swagger doesn't work properly with the plugin HOT 2
- permissions denied HOT 2
- instead of ip, name based urls HOT 4
- Problematic dependency on OpenSSL HOT 2
- Url not matching regex HOT 4
- Url not matching regex ^2 HOT 1
- To all contributors - notice to show support for UA
- Not working on windows 11 on MacBook Pro M1 via Parallels Desktop HOT 4
- Great utility HOT 1
- Support a range of ports?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from iisexpress-proxy.