VertiGIS Studio Web: Enable URLs without App ID
Non planifiéeAs a publisher of a web application in VertiGIS Studio Web (on prem), I want to be able to make URLs available to users that look like https://domain.com/someAppName instead of https://domain.com/somAppName?app=e763828b0d247310ba7d3e3725cf150f
While we could use redirect URLs to try and make this more friendly, users will still end up bookmarking these gross URLs that are hard to share and read and if we want to change it later (perhaps we release a new version that has a new ID) then they won't reference the old one. More than anything, this just makes it look more professional.
Ideally, there would be a way to hard code this ID in the index.html file and I could simply copy and rename the index.html file for each named application.
-
VertiGIS #19136
0 -
Hi Brandon - see the thread here: https://community.vertigis.com/hc/en-us/community/posts/4510274253074-Friendly-URL-for-Web-Viewer
0 -
That person just came up with a tool to redirect based on a query parameter. Setting up redirect URLs is easy. That's not the issue.
I did come up with two solutions that work, however:
In both cases, first setup a reverse proxy rule for domain.com/someApp to proxy to backend.host/vertigisstudio/web
Then do one of two things:
1. Set up a redirect rule in the proxy or web server from domain.com/someApp/default.json to redirect to the proper item url for the app config in your ArcGIS Portal/Online. This does exactly what we need and makes it just work. Downside? Doesn't work with secured apps (they gotta be public), and it's a bit hacky, and VertiGIS will likely not want to support that and I don't like giving vendors any excuses 😃2. This is the one we are going forward with, a little less sexy but very functional. Use the app ID and the /someApp/ path segment together to validate the url at the proxy and if the app ID is missing or does not match what it should be for /someApp/ then redirect to /someApp/?app=properAppID.
This way if we change the app ID for any reason, existing bookmarks will still work (will get redirected) and similarly if the app ID is not provided at all. It also means we don't have to track all the past app IDs, only the current one and everything else will redirect. We do something similar with various ArcGIS web apps since the IDs change on those all the time. Works great.
0
Vous devez vous connecter pour laisser un commentaire.
Commentaires
3 commentaires