Open cmalpeli opened 7 years ago
https://github.com/jtrupiano/rack-rewrite#host should work
@ShaneBoyer this solution doesn't actually seem to work for my case.
I've got:
r301 "/app", "/some-marketing-url", host: "www.domain1.com"
r301 "/app", "/another-marketing-url", host: "www.domain2.com"
The first rule applies. But the second redirect gets caught up by the first rule.....
My app serves up multiple domains. Is there a way to scope the rewrite to only one of them.
Essentially something that would allow this:
r301 'http://www.domain1.com/something', 'some-other-location'
So
http://www.domain1.com/something
would redirect, buthttp://www.domain2.com/something
would not.