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 Whitesource Scan to Build Workflow #64

Merged
merged 34 commits into from
May 11, 2023
Merged

Conversation

shooshmand-sol
Copy link
Collaborator

@shooshmand-sol shooshmand-sol commented May 10, 2023

What is the purpose of this change?

Adding Whitesource Scan to Build Workflow

How was this change implemented?

Whitesource scan step added to the build workflow, which does:

  • Download latest Mend/Whitesource Agent
  • Copy Maven Dependencies which copies all the dependencies to target/lib folder
  • Whitesource Scan to run the wss-unified-agent.jar scan against target/lib folder
    • Solace plugins have been exculded using WS_EXCLUDES
    • API key and Project token has been added as repository secrets and passed as env variables.

How was this change tested?

@@ -23,7 +23,7 @@ jobs:
contents: read
packages: write
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

upversion the plugin, to address this warning: actions/checkout#1047

Copy link
Collaborator

@johnvincentcorpuz johnvincentcorpuz left a comment

Choose a reason for hiding this comment

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

Looks good to me.

@@ -37,6 +37,16 @@ jobs:
export SKIP_FLAGS_NON_UNIT_TESTS="-Dcheckstyle.skip -Dpmd.skip -Dcpd.skip -Dfindbugs.skip -Dspotbugs.skip"
echo "SKIP_FLAGS_NON_UNIT_TESTS=$SKIP_FLAGS_NON_UNIT_TESTS" >> $GITHUB_ENV
echo "SKIP_FLAGS_ALL_TESTS=$SKIP_FLAGS_NON_UNIT_TESTS -Dmaven.test.skip=true" >> $GITHUB_ENV
if [[ $GITHUB_EVENT_NAME != "pull_request" && $GITHUB_REF_NAME=="main" ]]; then
Copy link
Collaborator

Choose a reason for hiding this comment

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

Trying to remember here the case where GITHUB_EVENT_NAME==pull_request and GITHUB_REF_NAME=="main". Why did we have to specify != pull_request?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good point, I also realized that $GITHUB_EVENT_NAME != "pull_request" is not necessary, for PRs GITHUB_REF_NAME vaule is pr_number/merge;
so going to drop that!

@shooshmand-sol shooshmand-sol merged commit e7d5951 into main May 11, 2023
1 check passed
@shooshmand-sol shooshmand-sol deleted the add_whitesource branch June 14, 2023 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants