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

Adding OSD in the distribution build pipeline with build script using volta to install nodejs dependencies #2841

Conversation

peterzhuamazon
Copy link
Member

Description

Make tweaks to dashboards plugin build script to support windows

Issues Resolved

#2306

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Your Name and others added 10 commits October 26, 2022 02:41
Signed-off-by: Your Name <you@example.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
…terzhuamazon/opensearch-build into opensearch-dashboards-support-2.4.0-1
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
@codecov-commenter
Copy link

codecov-commenter commented Nov 2, 2022

Codecov Report

Merging #2841 (1417f7a) into main (3eea73a) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #2841   +/-   ##
=======================================
  Coverage   93.66%   93.66%           
=======================================
  Files         158      158           
  Lines        4373     4373           
=======================================
  Hits         4096     4096           
  Misses        277      277           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
@peterzhuamazon peterzhuamazon force-pushed the opensearch-dashboards-support-2.4.0-1 branch from a16bbb4 to a6aea0f Compare November 2, 2022 23:54
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
Signed-off-by: Peter Zhu <zhujiaxi@amazon.com>
@peterzhuamazon peterzhuamazon changed the title Make tweaks to dashboards plugin build script to support windows Adding OSD build in the distribution build pipeline with build script using volta for nodejs installations Nov 3, 2022
@peterzhuamazon peterzhuamazon changed the title Adding OSD build in the distribution build pipeline with build script using volta for nodejs installations Adding OSD in the distribution build pipeline with build script using volta for nodejs installations Nov 3, 2022
@peterzhuamazon peterzhuamazon changed the title Adding OSD in the distribution build pipeline with build script using volta for nodejs installations Adding OSD in the distribution build pipeline with build script using volta to install nodejs dependencies Nov 3, 2022
H 1 * * * %INPUT_MANIFEST=2.3.1/opensearch-2.3.1.yml;TARGET_JOB_NAME=distribution-build-opensearch;BUILD_PLATFORM=linux macos
H 1 * * * %INPUT_MANIFEST=2.3.1/opensearch-dashboards-2.3.1.yml;TARGET_JOB_NAME=distribution-build-opensearch-dashboards;BUILD_PLATFORM=linux
H 1 * * * %INPUT_MANIFEST=2.3.1/opensearch-2.3.1.yml;TARGET_JOB_NAME=distribution-build-opensearch;BUILD_PLATFORM=linux macos windows
H 1 * * * %INPUT_MANIFEST=2.3.1/opensearch-dashboards-2.3.1.yml;TARGET_JOB_NAME=distribution-build-opensearch-dashboards;BUILD_PLATFORM=linux windows
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@peterzhuamazon are we going to 2.3.1 ?
@bbarani

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are planning 2.3.1 if needed thus still running the builds.

@prudhvigodithi
Copy link
Member

prudhvigodithi commented Nov 3, 2022

Hey @peterzhuamazon can the volta install be part of the agent, meaning can we pre-bake those packages to the agent?

@peterzhuamazon
Copy link
Member Author

Hey @peterzhuamazon can the volta install be part of the agent, meaning can we pre-bake those packages to the agent?

We already did that but just like container there are issues:

  1. Volta, just like NVM is using symlink during installation, which does not preserve after baking into an AMI. The better thing on Volta than NVM is that Volta is using a fixed path and automatically replace binaries on the fly during the build.

  2. A little confusion you may have is Volta does not have a use command, thus the volta install command here is simply switching the version that we already installed. Remember this image requires to have multiple versions of nodejs so 1.x/2.x/3.x can all be built.

  3. Install on the fly also allow us to reduce the number of AMIs to be generated just because a simple nodejs version change, which requires a redeploy of Jenkins to consume the new AMI.

Thanks.

@tianleh
Copy link
Member

tianleh commented Nov 3, 2022

Have we tested the change in a Jenkins job?

@peterzhuamazon
Copy link
Member Author

Have we tested the change in a Jenkins job?

Yes we have tested the PR with 2.4.0 builds:


2022-11-03 01:50:01 INFO     Installed plugins: ['alertingDashboards', 'anomalyDetectionDashboards', 'customImportMapDashboards', 'ganttChartDashboards', 'indexManagementDashboards', 'notificationsDashboards', 'observabilityDashboards', 'queryWorkbenchDashboards', 'reportsDashboards', 'searchRelevanceDashboards', 'securityAnalyticsDashboards', 'securityDashboards']

2022-11-03 01:54:18 INFO     Published C:\Users\Administrator\jenkins\workspace\zhujiaxi\bundle-build-zhujiaxi\zip\dist\opensearch-dashboards\opensearch-dashboards-2.4.0-windows-x64.zip.

@peterzhuamazon peterzhuamazon merged commit 14693cc into opensearch-project:main Nov 3, 2022
@peterzhuamazon peterzhuamazon deleted the opensearch-dashboards-support-2.4.0-1 branch November 3, 2022 03:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New Enhancement windows
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants