-
Notifications
You must be signed in to change notification settings - Fork 0
Chore: [AEA-0000] - remove trivy #66
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
Merged
+161
−152
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -1,91 +1,98 @@ | ||
| .PHONY: trivy-license-check trivy-generate-sbom trivy-scan-python trivy-scan-node trivy-scan-go trivy-scan-java | ||
anthony-nhs marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| trivy-license-check: | ||
| mkdir -p .trivy_out/ | ||
| @if [ -f poetry.lock ]; then \ | ||
| poetry self add poetry-plugin-export; \ | ||
| poetry export -f requirements.txt --with dev --without-hashes --output=requirements.txt; \ | ||
| fi | ||
| @if [ -f src/go.sum ]; then \ | ||
| cd src && go mod vendor; \ | ||
| fi | ||
| VIRTUAL_ENV=./.venv/ trivy fs . \ | ||
| --scanners license \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --pkg-types library \ | ||
| --exit-code 1 \ | ||
| --output .trivy_out/license_scan.txt \ | ||
| --format table | ||
| @if [ -f poetry.lock ]; then rm -f requirements.txt; fi | ||
| @if [ -f src/go.sum ]; then rm -rf src/vendor; fi | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
anthony-nhs marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| # @if [ -f poetry.lock ]; then \ | ||
| # poetry self add poetry-plugin-export; \ | ||
| # poetry export -f requirements.txt --with dev --without-hashes --output=requirements.txt; \ | ||
| # fi | ||
| # @if [ -f src/go.sum ]; then \ | ||
| # cd src && go mod vendor; \ | ||
| # fi | ||
| # VIRTUAL_ENV=./.venv/ trivy fs . \ | ||
| # --scanners license \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --pkg-types library \ | ||
| # --exit-code 1 \ | ||
| # --output .trivy_out/license_scan.txt \ | ||
| # --format table | ||
| # @if [ -f poetry.lock ]; then rm -f requirements.txt; fi | ||
| # @if [ -f src/go.sum ]; then rm -rf src/vendor; fi | ||
|
|
||
| trivy-generate-sbom: | ||
| mkdir -p .trivy_out/ | ||
| trivy fs . \ | ||
| --scanners vuln \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --exit-code 0 \ | ||
| --output .trivy_out/sbom.cdx.json \ | ||
| --format cyclonedx | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy fs . \ | ||
| # --scanners vuln \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --exit-code 0 \ | ||
| # --output .trivy_out/sbom.cdx.json \ | ||
| # --format cyclonedx | ||
|
|
||
| trivy-scan-python: | ||
| mkdir -p .trivy_out/ | ||
| trivy fs . \ | ||
| --scanners vuln \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --exit-code 1 \ | ||
| --skip-files "**/package-lock.json,**/go.mod,**/pom.xml" \ | ||
| --output .trivy_out/dependency_results_python.txt \ | ||
| --format table | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy fs . \ | ||
| # --scanners vuln \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --exit-code 1 \ | ||
| # --skip-files "**/package-lock.json,**/go.mod,**/pom.xml" \ | ||
| # --output .trivy_out/dependency_results_python.txt \ | ||
| # --format table | ||
|
|
||
| trivy-scan-node: | ||
| mkdir -p .trivy_out/ | ||
| trivy fs . \ | ||
| --scanners vuln \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --exit-code 1 \ | ||
| --skip-files "**/poetry.lock,**/go.mod,**/pom.xml" \ | ||
| --output .trivy_out/dependency_results_node.txt \ | ||
| --format table | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy fs . \ | ||
| # --scanners vuln \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --exit-code 1 \ | ||
| # --skip-files "**/poetry.lock,**/go.mod,**/pom.xml" \ | ||
| # --output .trivy_out/dependency_results_node.txt \ | ||
| # --format table | ||
|
|
||
| trivy-scan-go: | ||
| mkdir -p .trivy_out/ | ||
| trivy fs . \ | ||
| --scanners vuln \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --exit-code 1 \ | ||
| --skip-files "**/poetry.lock,**/package-lock.json,**/pom.xml" \ | ||
| --output .trivy_out/dependency_results_go.txt \ | ||
| --format table | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy fs . \ | ||
| # --scanners vuln \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --exit-code 1 \ | ||
| # --skip-files "**/poetry.lock,**/package-lock.json,**/pom.xml" \ | ||
| # --output .trivy_out/dependency_results_go.txt \ | ||
| # --format table | ||
|
|
||
| trivy-scan-java: | ||
| mkdir -p .trivy_out/ | ||
| trivy fs . \ | ||
| --scanners vuln \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --include-dev-deps \ | ||
| --exit-code 1 \ | ||
| --skip-files "**/poetry.lock,**/package-lock.json,**/go.mod" \ | ||
| --output .trivy_out/dependency_results_java.txt \ | ||
| --format table | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy fs . \ | ||
| # --scanners vuln \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --include-dev-deps \ | ||
| # --exit-code 1 \ | ||
| # --skip-files "**/poetry.lock,**/package-lock.json,**/go.mod" \ | ||
| # --output .trivy_out/dependency_results_java.txt \ | ||
| # --format table | ||
|
|
||
| trivy-scan-docker: guard-DOCKER_IMAGE | ||
| mkdir -p .trivy_out/ | ||
| trivy image $${DOCKER_IMAGE} \ | ||
| --scanners vuln \ | ||
| --severity HIGH,CRITICAL \ | ||
| --config trivy.yaml \ | ||
| --exit-code 1 \ | ||
| --pkg-types os,library \ | ||
| --output .trivy_out/dependency_results_docker.txt \ | ||
| --format table | ||
| echo "Not implemented" | ||
| # mkdir -p .trivy_out/ | ||
| # trivy image $${DOCKER_IMAGE} \ | ||
| # --scanners vuln \ | ||
| # --severity HIGH,CRITICAL \ | ||
| # --config trivy.yaml \ | ||
| # --exit-code 1 \ | ||
| # --pkg-types os,library \ | ||
| # --output .trivy_out/dependency_results_docker.txt \ | ||
| # --format table | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.