hpl123 wrote
PointsWell wrote
Currently I am working with client subdomains to connect to their personalised login pages, which makes for a cleaner url
client.yourwebservice.com
instead of
yourwebserice.com:8080/AwareIM/LoginClientName.html
The proxy route converts client.yourwebservice.com to the full URL internally, though you could use a directory instead of a subdomain.
Personally I feel like the subdomain is more personalised, but it is a "feels" and an opinion.
How is this setup? Do you have specific rewrite rules then, 1 for each client? My reverse proxy setup for example connects "https://yourwebservice.com/app/" to "localhost:8080" so if I want to login I would use "https://yourwebservice.com/app/logonAdmin.html" and the reverse proxy cannot in it´s core configuration it seems be configured to a specific file so additional rewrite rules (or something) needs to ne configured for that to work.
This was all with the assistance of Intra on here.
You create an NGINX directive for each sub domain. You obviously have to add a route to this for your internet domain. The start of the directive contains your server name i.e. the sub.yourdomain.com and then you create locations.
The default location within the directive goes to the logon page that you want to use for that specific client. I use one that has the Domain prepopulated. So the default path is to proxy pass to the internal IP address/AwareIM/logonPage.html
The result is that customerName.yourdomain.com
redirects to 123.45.67.89:8080/AwareIM/logonCustomerName.html
The end user only sees the customerName.yourdomain.com in the URL at login. It does however then start to show the full URL after login but there are ways to limit that. I haven't worked out how to mask it all yet (this translates to I haven't bothered intra enough to help me figure it out)
In the directive you include another directive to the generic error pages, I am guessing you could probably create custom error pages for each customer if you were so inclined.
Cerbot manages the SSL keys and will add all the required lines into the directive.