So I have been trying and failing at re-write conditions for a site that multiple subdomains for its site
The gist is that each market must direct and display code differently do to regulations
so
https://market1.product.com/
https://market2.product.com/
Should redirect to
https://market1.product.com/product-alias
https://market2.product.com/product-alias
Same alias, different subdomains
So I have tried setting the proxypass and reverseproxy pass and various iterations of rewrite cond and rules like so
this was an attempt to make root just go to either of the subdomains
proxypass / https://market1.product.com/product-alias
proxypass / https://market2.product.com/product-alias
This gives me a Proxy 502 error
This was an attempt to capture the site and pass the site to the alias
RewriteCond %{HTTP_HOST} ^([^\.]+)\.product\.com
RewriteCond /product-alias
RewriteRule ^(.*) /%1/$1 [L]
This just puts the alias about 7 times after the site name
For context the biggest thing is I am more of developer for backend things so I tend to not mess with apache conf files but have the most experience amongst the group so I was voluntold to work with it, and all of this is most likely my lack of understanding of apache httpd and also not fully understanding the directives that come with mod_proxy and mod_rewrite
I hope this makes sense and follows all the rules and appreciate any feedback on the type of question and context I should add in the future, I am mostly a lurker and use the site throguh google searches of errors and not really an architect