I have a b4j web server to demonstrate the potential of my web application to attract new customers. This is easy to do.
I wonder if it's a good idea to add to this website my web application (several google map javascript api with several markers {+3000})
I'm also wondering, how to separate clients that have multiple users. I thought of creating subdomains for each client like this
client1.domain.com
client2.domaine.com
And so on.
However, on the b4j web server, how to redirect the subdomains for the right clients.
Is it possible to create folders for each subdomain?
Why after user login not to check his properties ? Client id, role id, access rights in the interface... All these variants can be set for each user and used for routing by the URL, web-session...within the single domain.
I don't think creating multiple subdomains is a good idea. Unless you want to run separate B4J Web server jar for each individual customer. If yes I would prefer to use different port numbers.
nginx proxy manager (for linux servers only)... Also if it is containerized in docker the same port(s) can be used for all servers (containers) and nginx proxy manager will divert each subdomain to a different container.
IMHO, the system should be smart enough using just one domain, one port, one SSL sertificate, one DB, one app .jar.... to distinguish any user, if he logged in correctly. Or cluster of hosts, but internally redirected after login.
I mentioned something before but I suppose as I was not aware of it before I research it and get the knowledge I wanted, so are other people in here. What nginx proxy manager does is that it can create by itself an https connection outside and communicate inside VPS with the webapp in proper port with http so what it does is this:
Client <------ https communication ------> Nginx Proxy Manager <------ http communication -------> B4J webapp
You do not need in the webapp SSL certificate. You just create the subdomain (or new domain), you give it to it (NPM) and select "Add Let's Encrypt SSL" certificate and you direct the flow to the app (ip/port). Then click "create host" and it does it all by itself.