-
Notifications
You must be signed in to change notification settings - Fork 919
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
[Branding] Support for Local File Paths in branding configuration #1022
Comments
Hey @ABurns1263, thanks for opening this. If you could clarify:
Are you serving up like images locally? The branding should have access to localhost images as long as you are serving up those images with your own web server to be accessible by localhost. But if you are just attempting to access files directly from localhost it shouldn't work. If you don't really want to go about creating a web server to host those images or utilize a cloud storage. There is a workaround: This is assuming you downloaded the release and hosting on 5601 (but you can supplement your port), but anything under For example if I put a
But there are some cons with that:
I believe the application checks if those values are set and serves the SSL files to be accessible by the application from the file path provided. Which is do-able but might be backlogged unless a member of the community would like to implement it. One final point: I see #1019. This might be another option as well. |
Problem is here - https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/rendering/rendering_service.tsx#L317 - this code must be reimplemented to allow configuration like so |
Sorry about the late reply! In this do you propose to pointing to the github repo? @enp @ABurns1263, I believe we can hijack this issue to allow for adding assets folder at the root level of the application that can be served up under |
Specific directory not mandatory, predefined looks enough |
Colleagues, is there any news on this feature? @kavilla ? |
I just tried to put an image in the src/core/server/core_app/assets folder and try to use it in the yml file and it does not work. I did the exact same thing that you described but I still get :
Is it possible that you missed something? |
Hey @Ironem, There is an update https://opensearch.org/docs/latest/dashboards/branding/, for There's also a note about SSL in the docs, if you are have With that if you hit Let me know! Thank you! |
Hi @kavilla, Thank you for your response. So as you mentioned, in 1.3 release, we can put files directly in the root assets folder, and we can point to it with So I'm wondering if it's possible to put a absolute path in yml like: Thank you again! |
Hello @kavilla, do you have any updates on this issue? |
Hi @kavilla, мaybe there was some movement in solving this issue, which stretches from release to release? |
Hi, any news on this ? I have the same issue. |
I patch the file _defineProperty(this, "isUrlValid", async (url, configname) => {
if (url === '/') {
return false;
}
/** Workaround: support for relative URL, does nothing if URL is absolute/contains host info
* TODO: Retrieve protocol + port from configuration
*/
url = new URL(url, 'https://localhost:5601').toString();
... A related note: If you are using server base path, you need to include that with your icon URL (with or without the patch) server.basePath: /foobar
server.rewriteBasePath: true
opensearchDashboards.branding:
logo:
defaultUrl: "/foobar/ui/..." # with patch
defaultUrl: "https://localhost:5601/foobar/ui/..." # without patch
... |
Same problem but in my case, I would like that the solution doesn't require to indicate a base path as in @git-blame's comment... It should agnostic over it as in the default paths that includes the
|
Is your feature request related to a problem? Please describe.
My company requires being able to reference a local image for branding, instead of a url to an image, in the opensearch_dashboards.yaml file.
Describe the solution you'd like
We would like to be able to use local file paths in the branding configuration, as ssl key and configuration do in the same file.
Describe alternatives you've considered
We have tried to reference local file paths using
http://localhost:
http://127.0.0.1
file:///
before our local file path to icons, however these did not configure the images onto opensearch dashboards
The text was updated successfully, but these errors were encountered: