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

Add workflow to build and install security analytics dashboards plugin #899

Merged
merged 12 commits into from
Mar 18, 2024

Conversation

derek-ho
Copy link
Contributor

@derek-ho derek-ho commented Feb 23, 2024

Description

This PR adds a workflow to build and install the security analytics plugin in to OSD, and verifies there are no run time failures. The current setup in which a development server is run (i.e. running yarn start from OSD root), does not catch issues such as imports and other intricacies that happen with the build and installation process. Inspired from: opensearch-project/opensearch-build#4115 (comment), this workflow will be helpful in catching cases like this.

To demonstrate the value of this PR, I reverted the recent fix that fixed some issues found at run time with the security analytics dashboards plugin, and verified that the workflow would have caught this: https://github.com/opensearch-project/security-analytics-dashboards-plugin/actions/runs/8023274575/job/21919423391. There are ways to catch this today, such as autocuts, but this workflow run on each PR will keep the repo in a good state and catch these issues early.

Check List

  • Commits are signed per the DCO using --signoff

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.

Copy link

codecov bot commented Feb 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 31.03%. Comparing base (bb72562) to head (634aae0).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #899   +/-   ##
=======================================
  Coverage   31.03%   31.03%           
=======================================
  Files         157      157           
  Lines        5229     5229           
  Branches      925      925           
=======================================
  Hits         1623     1623           
  Misses       3419     3419           
  Partials      187      187           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@derek-ho derek-ho changed the title Test workflow Add workflow to build and install security analytics dashboards plugin Feb 23, 2024
@derek-ho derek-ho marked this pull request as ready for review February 23, 2024 18:41
@@ -106,7 +106,7 @@ jobs:
- name: Bootstrap plugin/OpenSearch-Dashboards
run: |
cd OpenSearch-Dashboards/plugins/security-analytics-dashboards-plugin
yarn osd bootstrap
yarn osd bootstrap --single-version=loose
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is necessary after core added a dependency on cypress 9.5.4. See opensearch-project/OpenSearch-Dashboards#5561 for more context

@derek-ho
Copy link
Contributor Author

@AWSHurneyt @riysaxen-amzn can you take a look at this PR and leave any feedback? I think it will be helpful to catch issues early.

Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
This reverts commit ba9c4f6.

Signed-off-by: Derek Ho <dxho@amazon.com>
…ect#875)""

This reverts commit 17cff14.

Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
@amsiglan amsiglan merged commit 6bb078b into opensearch-project:main Mar 18, 2024
10 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Mar 18, 2024
#899)

* Initial commit to try using workflow from other fork

Signed-off-by: Derek Ho <dxho@amazon.com>

* setup with backend or job scheduler

Signed-off-by: Derek Ho <dxho@amazon.com>

* Use generalized workflows

Signed-off-by: Derek Ho <dxho@amazon.com>

* Extra dash

Signed-off-by: Derek Ho <dxho@amazon.com>

* Correct directory

Signed-off-by: Derek Ho <dxho@amazon.com>

* Revert "Add missing modules common and types (#875)"

This reverts commit ba9c4f6.

Signed-off-by: Derek Ho <dxho@amazon.com>

* Revert "Revert "Add missing modules common and types (#875)""

This reverts commit 17cff14.

Signed-off-by: Derek Ho <dxho@amazon.com>

* Single version loose to fix bootstrapping issues

Signed-off-by: Derek Ho <dxho@amazon.com>

* Add v1 tag

Signed-off-by: Derek Ho <dxho@amazon.com>

* Remove security specific settings

Signed-off-by: Derek Ho <dxho@amazon.com>

* Remove references to security

Signed-off-by: Derek Ho <dxho@amazon.com>

* Add loose for windows

Signed-off-by: Derek Ho <dxho@amazon.com>

---------

Signed-off-by: Derek Ho <dxho@amazon.com>
(cherry picked from commit 6bb078b)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
amsiglan pushed a commit that referenced this pull request Mar 19, 2024
#899) (#958)

* Initial commit to try using workflow from other fork



* setup with backend or job scheduler



* Use generalized workflows



* Extra dash



* Correct directory



* Revert "Add missing modules common and types (#875)"

This reverts commit ba9c4f6.



* Revert "Revert "Add missing modules common and types (#875)""

This reverts commit 17cff14.



* Single version loose to fix bootstrapping issues



* Add v1 tag



* Remove security specific settings



* Remove references to security



* Add loose for windows



---------


(cherry picked from commit 6bb078b)

Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants