Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for UI under a path example.com/cloudify/console #1680

Open
aitorhh opened this issue Nov 23, 2021 · 1 comment
Open

Support for UI under a path example.com/cloudify/console #1680

aitorhh opened this issue Nov 23, 2021 · 1 comment

Comments

@aitorhh
Copy link

aitorhh commented Nov 23, 2021

I haven't found a way to use a subpath for the UI externally (without rebuilding the cloudify-stage/).

It would be great if you could include an option to set the baseUrl by, for example, reading environmental variable. For example in Vue.js: https://cli.vuejs.org/config/#publicpath, or with react https://medium.com/@svinkle/how-to-deploy-a-react-app-to-a-subdirectory-f694d46427c1. However these options will be only valid when re-building the application.

Also, in angular that is possible dynamically by using the localtion.pathname of the requests. It is something like:

export function getBaseLocation() {
    let paths: string[] = location.pathname.split('/').splice(1, 1);
    let basePath: string = (paths && !ROUTES_PATH.includes(paths[0]) && paths[0]) || ''; // Default: ''
    return '/' + basePath;
}

And declaring in the providers:

{
provide: APP_BASE_HREF,
useFactory: getBaseLocation
}

@qooban
Copy link
Contributor

qooban commented Nov 26, 2021

@aitorhh
Thanks for reporting the issue. As far as I know we are not planning any changes in terms of adding support for custom base URL. If you are interested in it, could you please create a Pull Request with desired changes and let me know?

For the future - we are not using GitHub for issue tracking, please use our Slack channel: https://cloudify.co/slack/ to ask for support or report issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants