-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* merge dependabot * update DependencyCheck * test github action with agent * change project * change config 1 * change config 2 * change config 3 * test github action with config server * test github action with config server ui * remove build from depcheck * test github action with configdocsgenerator * remove unnecessary property * use action in release * add cron jobs * reinclude build to depcheck * try including configdocsgenerator * try including configdocsgenerator 2 * try including configdocsgenerator 3 * try including configdocsgenerator 4 * try including configdocsgenerator 5 * try including configdocsgenerator 6 * try including configdocsgenerator 7 * try including configdocsgenerator 8 * try including configdocsgenerator 9 * included configsdocsgenerator and UI * refactor config-server workflow
- Loading branch information
Showing
11 changed files
with
254 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Automatic Security Check Agent | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # At 08:00 on day-of-month 1 and 15 | ||
|
||
jobs: | ||
security-check: | ||
name: Security Check Agent | ||
runs-on: ubuntu-latest | ||
container: eclipse-temurin:8-jdk | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
- name: build | ||
run: ./gradlew :inspectit-ocelot-agent:assemble | ||
- name: Run DependencyCheck plugin | ||
uses: dependency-check/Dependency-Check_Action@main | ||
id: depcheck | ||
continue-on-error: true | ||
with: | ||
project: inspectIT/inspectit-ocelot-agent | ||
path: 'inspectit-ocelot-agent' | ||
format: 'HTML' | ||
args: > | ||
--disableAssembly | ||
--disableNodeAudit | ||
--nvdApiKey ${{ secrets.NVD_API_KEY }} | ||
--nvdApiDelay 10000 | ||
- name: Upload test results | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: dependency-check-report-ocelot-agent | ||
path: ${{ github.workspace }}/reports | ||
- name: Send Notification | ||
uses: slackapi/[email protected] | ||
with: | ||
webhook: ${{ secrets.SLACK_WEBHOOK_URL }} | ||
webhook-type: incoming-webhook | ||
payload: | | ||
text: "*Ocelot-Agent Dependency-Check Report*: ${{ steps.depcheck.outcome }}\nPlease check the report here: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | ||
# if DependencyCheck failed, the job should also fail, but only after the results were uploaded | ||
- name: Validate DependencyCheck outcome | ||
if: ${{ steps.depcheck.outcome == 'failure' }} | ||
run: | | ||
echo "DependencyCheck failed" | ||
exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
name: Automatic Security Check Configuration-Server | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # At 08:00 on day-of-month 1 and 15 | ||
|
||
jobs: | ||
security-check: | ||
name: Security Check Configuration-Server | ||
runs-on: ubuntu-latest | ||
container: eclipse-temurin:17 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Grant execute permission for gradlew | ||
run: chmod +x gradlew | ||
- name: build Configuration-Server | ||
run: ./gradlew :inspectit-ocelot-configurationserver:bootJarWithFrontend | ||
- name: Run DependencyCheck Backend | ||
uses: dependency-check/Dependency-Check_Action@main | ||
id: depcheck | ||
continue-on-error: true | ||
with: | ||
project: inspectIT/inspectit-ocelot-configuration-server | ||
path: 'components/inspectit-ocelot-configurationserver' | ||
format: 'HTML' | ||
out: 'reports/configuration-server' | ||
args: > | ||
--disableAssembly | ||
--disableNodeAudit | ||
--nvdApiKey ${{ secrets.NVD_API_KEY }} | ||
--nvdApiDelay 10000 | ||
- name: Run DependencyCheck UI | ||
uses: dependency-check/Dependency-Check_Action@main | ||
id: depcheck-ui | ||
continue-on-error: true | ||
with: | ||
project: inspectIT/inspectit-ocelot-configuration-server-ui | ||
path: 'components/inspectit-ocelot-configurationserver-ui' | ||
format: 'HTML' | ||
out: 'reports/configuration-server-ui' | ||
args: > | ||
--disableAssembly | ||
--disableNodeAudit | ||
--nvdApiKey ${{ secrets.NVD_API_KEY }} | ||
--nvdApiDelay 10000 | ||
- name: build ConfigDocsGenerator | ||
run: ./gradlew :inspectit-ocelot-configdocsgenerator:assemble | ||
- name: Run DependencyCheck ConfigDocsGenerator | ||
uses: dependency-check/Dependency-Check_Action@main | ||
id: depcheck-docs | ||
continue-on-error: true | ||
with: | ||
project: inspectIT/inspectit-ocelot-configdocsgenerator | ||
path: 'components/inspectit-ocelot-configdocsgenerator' | ||
format: 'HTML' | ||
out: 'reports/configdocsgenerator' | ||
args: > | ||
--disableAssembly | ||
--disableNodeAudit | ||
--nvdApiKey ${{ secrets.NVD_API_KEY }} | ||
--nvdApiDelay 10000 | ||
- name: Upload test results | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: dependency-check-report-ocelot-configurationserver | ||
path: ${{ github.workspace }}/reports | ||
- name: Set DependencyCheck status | ||
run: | | ||
if [ ${{ steps.depcheck.outcome == 'failure' || steps.depcheck-ui.outcome == 'failure' || steps.depcheck-docs.outcome == 'failure' }} == "true" ]; then | ||
echo "DEP_CHECK_STATUS=failure" >> $GITHUB_ENV | ||
else | ||
echo "DEP_CHECK_STATUS=success" >> $GITHUB_ENV | ||
fi | ||
- name: Send Notification | ||
uses: slackapi/[email protected] | ||
with: | ||
webhook: ${{ secrets.SLACK_WEBHOOK_URL }} | ||
webhook-type: incoming-webhook | ||
payload: | | ||
text: "*Ocelot-Configuration-Server Dependency-Check Report*: ${{ env.DEP_CHECK_STATUS }}\nPlease check the report here: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | ||
# if DependencyCheck failed, the job should also fail, but only after the results were uploaded | ||
- name: Validate DependencyCheck outcome | ||
if: ${{ env.DEP_CHECK_STATUS == 'failure' }} | ||
run: | | ||
echo "DependencyCheck failed" | ||
exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters