This topic has 6 replies, 3 voices, and was last updated 5 years, 10 months ago by pankajgoyal0801.
-
AuthorPosts
-
September 15, 2016 at 12:51 pm #13019
pankajgoyal0801
ParticipantHi,
I have two assets accessible as below :
1) http://asset1.example.com/
2) http://asset2.example.com/How can I support these two assets using OpenIG? As there is no path component, I cannot use requestPath match condition in 99-default.json.
I don’t know whether it is possible or not?
September 15, 2016 at 1:25 pm #13020Laurent Vaills
ParticipantHi,
You should be able to differentiate these 2 assets by using
request.uri.host
in either the functionmatches
like this :${matches(request.uri.path, '^asset1')
or like this :${request.uri.host = 'asset1.example.com}
Regards,
Laurent-
This reply was modified 5 years, 11 months ago by
Laurent Vaills.
-
This reply was modified 5 years, 11 months ago by
Laurent Vaills.
September 15, 2016 at 2:11 pm #13024pankajgoyal0801
ParticipantHow can I use request.uri.host because it will always contain “openig.example.com”?
September 15, 2016 at 2:48 pm #13026Laurent Vaills
ParticipantCan you please detail a bit more the context in which you’re using OpenIG ?
September 15, 2016 at 3:15 pm #13027pankajgoyal0801
ParticipantMachine 1 – asset1 (asset1.example.com)
Machine 2 – openig (openig.example.com)Browser – openig.example.com/asset1 – (Working if I use requestPath match condition)
But if I access openig.example.com/ and I have multiple assets, then I am stuck into that problem.I am seeing that I can add Alias in Tomcat Conf where openig is deployed. If I add asset1.example.com as alias and redirect asset1.example.com requests from browser to Machine 2, then I think matching request uri host part will help…
Have you got my point?
September 19, 2016 at 6:44 am #13067Mark de Reeper
ParticipantHi,
In this use-case you need to alias the two different FQDN’s (asset1.example.com and asset2.example.com) to point to the instance of OpenIG and from there OpenIG can proxy though to the appropriate application, end users should not be able to hit the applications directly and always go via OpenIG for it to be working as a true proxy.
Thanks
Mark
September 19, 2016 at 8:09 am #13069pankajgoyal0801
ParticipantYes. I tried that and it worked !!
Thanks !! :)
-
This reply was modified 5 years, 11 months ago by
-
AuthorPosts
You must be logged in to reply to this topic.