Is it possible to provide access to the NGClient using nice urls.
For instance: https://www.example.com/welcome to access the inlog page, and next https://www.example.com/home to access the main page?
And to take it one step further, is this also possible:
https://customer_1.example.com/welcome to show a branded inlog page where the user doesnot have to enter his company name but only username/password
What is possible within the NGClient remains to be seen. Maybe it is possible to customize the router used internally by the NGClient, but I haven’t attempted that (yet) not have I heared anyone else doing that.
However, usually your Servoy Application Server is not directly exposed to the internet, but access to it goes through a Reverse Proxy (usually based on Apache HTTP server or NGInx. Both support rewritting URL’s, so if you have some naming convention/logic how to derive the formName (and thus NGClient url) from the nice url the user sees, you can use the url rewrite logic to get the ‘nice url’ part of your question done.
The second part (subdomains per (SaaS) customer) is for sure something you’d handle within the Reverse Proxy between the internet and your Servoy App Server. The implementation of it depends on the setup of your deployment architecture (1 big SaaS server hosting all your customers vs. multiple servers to host them all vs 1 server per customer etc). The whole thing starts with a wildcard entry in the DNS to whatever subdomains is put in from of example.com is supported and end up on your Reverse Proxy. The rest depends, as said, on your deployment architecture and how easy you want to have it to get a new customer up and running. Trying to lay out all options/scenarios/possibilities are too much to put on the forum, if you ask me.
Hope this helps,
Paul
jdbruijn:
Is it possible to provide access to the NGClient using nice urls.
For instance: https://www.example.com/welcome to access the inlog page, and next https://www.example.com/home to access the main page?
Yes. A few options. I’m personally not a fan of putting a proxy in front of the Servoy App server in all deployments. I think the only time you want something in front of your Servoy server is if you are using a load balancer and running several servoy app server instances. If your using a load balancer, you can setup some rules for how the URL structures work.
If you aren’t using a load balancer, and just doing a normal servoy deployment, there are 2 main options.
- Use iFrames. So in your application_server/server/webapps/ROOT folder, you can make some static .html pages that have a deep link into the web/NG client.
- Use something like this to rewrite the URL’s: http://tuckey.org/urlrewrite/ Its a similar concept to mod_rewrite in PHP. Works in Web and NG Client
jdbruijn:
And to take it one step further, is this also possible:
https://customer_1.example.com/welcome to show a branded inlog page where the user doesnot have to enter his company name but only username/password
Yes, this is easy to do in Servoy, Web Client or NG Client. On your Login page, in your onLoad, you can get the URL, and then retrieve the proper branding and render the login page accordingly. For example, I think the call is application.getServerURL() if I remember correctly. Then you can use security.authenticate(…) and pass in the url info, and have it return back the branding info so you can render the proper logo and company name.
Thanks Paul and Scott,
I will look into your suggestions