-
Notifications
You must be signed in to change notification settings - Fork 901
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
How to create React Production Build of OpenSearch Dashboard #7599
Comments
@Siddhesh-Shinde If you only added a new plugin but did not modify the OpenSearch-Dashboards code, you only need to build the plugin(you will get a .zip file) and install it to the official OpenSearch-Dashboards distributions |
@ruanyl I have modified the OpenSearch Dashboard code as well like modifying the UI for instance, along with adding a fresh new plugin. How should I create the React production build then? |
@Siddhesh-Shinde I tried in my local, but I cannot reproduce the error. By looking at the error message, it looks like it has something to do with your network condition. |
@ruanyl Can you share the commands you executed and the corresponding logs so that I can have a glance at it |
You should see the correct nodejs version downloaded successfully
|
Gives me self signed certificate error mentioned above in image |
When I ran the command For any Mac users/anyone else out there facing this issue, I recommend setting up the codebase on a Linux VM and running the build command there. This solution worked for me, and it should hopefully resolve the issue for you as well. Next you need to build the plugin as a .zip file and then install it to your OpenSearch Dashboard distribution You can follow the steps below for it:
|
Versions: 2.13.0 OpenSearch Dashboard
Describe the issue:
I have created a new plugin on top of the Opensearch Dashboard code. I'm intending to create a production build of the whole application. For any React application created using Create React App, we run the
npm run build
command. On looking at the OpenSearch Dashboard codebase, I found that the package.json contains custom scripts for build and almost everything. I also checked the Developer Guide readme present in OpenSearch Dashboard Github Repository. And I found a section named Building artifacts over there. Reference: https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/DEVELOPER_GUIDE.md#building-artifactsIt suggest running
yarn build
command. I tried running the command, but I'm getting self signed certificate error that too in the axios npm module. I'm wondering how to tackle this error or if there is any alternative way to create a React production build then please let me know. I would be thankful.I have tried with
export NODE_TLS_REJECT_UNAUTHORIZED=0
as well, but that also didn't workConfiguration:
NA
Relevant Logs or Screenshots:
The text was updated successfully, but these errors were encountered: