Configuring Multiple Endpoints for a Single Radzen Angular Application

Hello Radzen Community,

I am currently working with a Radzen Angular application deployed to both production and test environments, hosted on a server with IIS. For example, the URLs for these environments are:

  • Test: https://loginacc.hostname.com/firstApp/
  • Production: https://login.hostname.com/firstApp/

I handle deployments directly from within Radzen. The test and production environments use separate databases.

I now need to set up additional endpoints for the same application code base, allowing users to access the application from different URLs. The desired additional URLs are, for example:

  • Test: https://loginacc.hostname.com/secondApp/
  • Production: https://login.hostname.com/secondApp/

The application, database, and users remain the same within each environment, but the app should recognize which URL it is running on.

Has anyone in the community configured Radzen to deploy the same application to multiple endpoints? If so, could you share your experience ? Specifically, I am looking for advice on:

  1. How to deploy the application to multiple endpoints from Radzen.:
    ( I already use load deploy settings to deploy to prod or test env.)
  2. Ensuring the application can detect and respond to the different URLs appropriately.

PS: I'm not particularly looking for a multi-tenancy solution, but if that's the way to go..

My main goal is to use Radzen's capabilities as much as possible and minimize customizations.

Thank you!

Best Regards,
Mehmet

This is supported out of the box when deploying to IIS.

You can try modifying the config.service.ts file. The get method is used for retrieving a URL for a data source. You can put there a check for the URL.

Hi @korchev ,

I’ve modified security.service.ts and config.service.ts to detect the URL where the app is running. I pass this information to the security service, making it available in Radzen Studio for use with the login screen and application page title. This works great , thank you for the pointer .

I have one issue that I want to resolve: Is it possible to change the start page (the one we can set in the Radzen Designer) based on the URL ?

/Mehmet

I don't think so (or I just don't know how) - the start page is configured in the router for the "/" path.

I have solved it by adding a redirect on the start page. Now, with the environment based on the running URL in my security service, the redirect can be done within the page itself.

Have a nice day!