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

Security Workflow #611

Merged
merged 7 commits into from
Nov 30, 2022

Conversation

bowenlan-amzn
Copy link
Member

@bowenlan-amzn bowenlan-amzn commented Nov 17, 2022

Issue #, if available:
#612

Description of changes:

During 2.4 release, we only caught this bug #608 until Infra runs security test. A code change was made in security enabled code path, but we don't have security test running along with each PR.

This PR dives deep into the way of running security test using github workflow and resolve the long standing problem of SSL connection error when directly run security test using integTest task.

CheckList:

  • 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.

@codecov-commenter
Copy link

codecov-commenter commented Nov 17, 2022

Codecov Report

Merging #611 (d65b85e) into main (a21e4a6) will decrease coverage by 0.07%.
The diff coverage is 50.00%.

@@             Coverage Diff              @@
##               main     #611      +/-   ##
============================================
- Coverage     75.32%   75.24%   -0.08%     
+ Complexity     2605     2588      -17     
============================================
  Files           330      330              
  Lines         15111    15115       +4     
  Branches       2337     2338       +1     
============================================
- Hits          11382    11374       -8     
+ Misses         2397     2396       -1     
- Partials       1332     1345      +13     
Impacted Files Coverage Δ
...transport/action/explain/TransportExplainAction.kt 70.75% <0.00%> (ø)
.../rollup/action/index/TransportIndexRollupAction.kt 72.09% <0.00%> (ø)
...agement/indexstatemanagement/ManagedIndexRunner.kt 47.13% <60.00%> (+1.35%) ⬆️
...ensearch/indexmanagement/util/JobSchedulerUtils.kt 73.91% <100.00%> (ø)
...statemanagement/validation/ValidateReplicaCount.kt 0.00% <0.00%> (-32.15%) ⬇️
...nt/indexstatemanagement/model/destination/Slack.kt 55.55% <0.00%> (-22.23%) ⬇️
...ndexstatemanagement/validation/ActionValidation.kt 86.66% <0.00%> (-13.34%) ⬇️
...ndexstatemanagement/validation/ValidateRollover.kt 66.66% <0.00%> (-9.53%) ⬇️
...dexmanagement/transform/model/TransformMetadata.kt 83.49% <0.00%> (-8.74%) ⬇️
.../indexstatemanagement/validation/ValidateDelete.kt 47.05% <0.00%> (-5.89%) ⬇️
... and 15 more

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

@bowenlan-amzn bowenlan-amzn force-pushed the securityworkflow branch 10 times, most recently from c5a44f6 to d867f9b Compare November 17, 2022 08:28
Signed-off-by: bowenlan-amzn <[email protected]>
@bowenlan-amzn bowenlan-amzn force-pushed the securityworkflow branch 5 times, most recently from 6f8d25c to 0b5170b Compare November 17, 2022 18:02
@bowenlan-amzn bowenlan-amzn force-pushed the securityworkflow branch 3 times, most recently from 6c86be5 to 341b48c Compare November 17, 2022 18:31
Signed-off-by: bowenlan-amzn <[email protected]>
@bowenlan-amzn bowenlan-amzn force-pushed the securityworkflow branch 5 times, most recently from cdedcf0 to 4c8b15f Compare November 18, 2022 05:31
@bowenlan-amzn bowenlan-amzn force-pushed the securityworkflow branch 4 times, most recently from 70368e1 to 134df7b Compare November 21, 2022 02:15
@bowenlan-amzn bowenlan-amzn marked this pull request as ready for review November 21, 2022 06:04
@bowenlan-amzn bowenlan-amzn requested a review from a team November 21, 2022 06:04
Signed-off-by: bowenlan-amzn <[email protected]>
@Angie-Zhang Angie-Zhang merged commit f2a9fa6 into opensearch-project:main Nov 30, 2022
opensearch-trigger-bot bot pushed a commit that referenced this pull request Nov 30, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)
@bowenlan-amzn bowenlan-amzn deleted the securityworkflow branch November 30, 2022 21:13
Angie-Zhang pushed a commit that referenced this pull request Nov 30, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)

Co-authored-by: bowenlan-amzn <[email protected]>
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.4 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.4 2.4
# Navigate to the new working tree
cd .worktrees/backport-2.4
# Create a new branch
git switch --create backport/backport-611-to-2.4
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 f2a9fa6ef05227f3c048b5e59a5852b18c1e98e1
# Push it to GitHub
git push --set-upstream origin backport/backport-611-to-2.4
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.4

Then, create a pull request where the base branch is 2.4 and the compare/head branch is backport/backport-611-to-2.4.

Angie-Zhang pushed a commit to Angie-Zhang/index-management that referenced this pull request Dec 8, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)
opensearch-trigger-bot bot added a commit that referenced this pull request Dec 9, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)

Co-authored-by: bowenlan-amzn <[email protected]>
(cherry picked from commit ed54fee)
Angie-Zhang pushed a commit to Angie-Zhang/index-management that referenced this pull request Dec 12, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
Angie-Zhang pushed a commit to Angie-Zhang/index-management that referenced this pull request Dec 12, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
bowenlan-amzn added a commit to bowenlan-amzn/index-management that referenced this pull request Dec 28, 2022
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
bowenlan-amzn added a commit that referenced this pull request Jan 3, 2023
* Security Workflow (#611)

* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>

* Fix deps missing

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
wuychn pushed a commit to ochprince/index-management that referenced this pull request Mar 16, 2023
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)

Co-authored-by: bowenlan-amzn <[email protected]>
@bowenlan-amzn bowenlan-amzn mentioned this pull request May 16, 2023
ronnaksaxena pushed a commit to ronnaksaxena/index-management that referenced this pull request Jul 19, 2023
* Unify wipe indices logic after tests

Signed-off-by: bowenlan-amzn <[email protected]>

* Enhance wipeAllIndices function

Signed-off-by: bowenlan-amzn <[email protected]>

* security workflow setup

Signed-off-by: bowenlan-amzn <[email protected]>

* add more settings

Signed-off-by: bowenlan-amzn <[email protected]>

* Rewrite SecureRestClientBuilder

Signed-off-by: bowenlan-amzn <[email protected]>

* For now, use local cluster

Signed-off-by: bowenlan-amzn <[email protected]>

Signed-off-by: bowenlan-amzn <[email protected]>
(cherry picked from commit f2a9fa6)

Co-authored-by: bowenlan-amzn <[email protected]>
Signed-off-by: Ronnak Saxena <[email protected]>
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.

4 participants