we have 2 Urls pointing to same apache instance. One URL, for Admin and other for client's. When accessing admin URL, should allow /admin where as /admin should be denied while accessing through client URL. Could you help with sample apache rewrite rules.
https://example-admin.com/admin - Admins allowed to access admin url
https://example-client.com/admin - Client should not allowed to access admin url
https://example-client.com/client - Client allowed to access client site
UPDATE:
I tried this below to block admin context path for client URL. But this isn't working:
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/auth/admin(/.*)? [NC]
RewriteRule ^ - [F]