- Notifications
You must be signed in to change notification settings - Fork 37
Add automated security scanning workflows #124
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
Open
ausbru87 wants to merge 15 commits into main Choose a base branch from 123-add-security-scanning
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline, and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
15 commits Select commit Hold shift + click to select a range
9b0ab3a ci: add security scanning workflows (#123)
ausbru87 351ea5c ci: scan for all CVE severity levels and remove Docker image scan
ausbru87 980a039 ci: add explicit scanners to Trivy configuration
ausbru87 9f26520 ci: build and scan Docker image like coder/coder
ausbru87 9e22e3a ci: add table output and artifact upload for scan visibility
ausbru87 9c091a9 ci: add workflow_dispatch trigger to scorecard for manual testing
ausbru87 d3b966a revert: remove workflow_dispatch from scorecard
ausbru87 949cdba removed changes from changelog.md
ausbru87 6b8d181 updated Make for multiple targets and updated security.yaml to use ma…
ausbru87 c3339da added sha pinning
ausbru87 2a40050 Updated SHAs
ausbru87 4769896 added explicit build targets for each arch
ausbru87 ad4db42 added explicit make build command instead of alias to security workflow
ausbru87 0f66771 removed prefixes due to changelog.md being manually curated
ausbru87 4bac609 reduce potential of credential leak by removing credential persistence
ausbru87 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
updated Make for multiple targets and updated security.yaml to use ma…
…ke and bake.
- Loading branch information
commit 6b8d1813632a8083f9cd90af3ecd1307a68d1537
Some comments aren't visible on the classic Files Changed page.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| | @@ -27,6 +27,11 @@ upload: | |
| | ||
| TAG=$(shell git describe --always) | ||
| | ||
| build/linux/amd64: | ||
deansheather marked this conversation as resolved. Outdated Show resolved Hide resolved | ||
| mkdir -p bin | ||
| Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You could maybe just put a | ||
| CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-X github.com/coder/code-marketplace/buildinfo.tag=$(TAG)" -o bin/code-marketplace-linux-amd64 ./cmd/marketplace/main.go | ||
| .PHONY: build/linux/amd64 | ||
| | ||
| build: | ||
| CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -ldflags "-X github.com/coder/code-marketplace/buildinfo.tag=$(TAG)" -o bin/code-marketplace-mac-amd64 ./cmd/marketplace/main.go | ||
| CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -ldflags "-X github.com/coder/code-marketplace/buildinfo.tag=$(TAG)" -o bin/code-marketplace-mac-arm64 ./cmd/marketplace/main.go | ||
| | ||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can keep the PHONY (after editing the target name) for simplicity's sake though, otherwise you'll need to specify every Go-related file as a dependency
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would it be better to leave PHONY or to use a pattern like one of the following to ensure Make can still optimize by not building if no Go files change?
bin/code-marketplace-linux-amd64: $(wildcard **/*.go) go.mod go.sumIf you think leaving PHONY is simpler and cleaner then I am open just like using Make to optimize builds even in small repos like this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you want to do it you'll probably have to use
shell findcuz I don't think make'swildcardis very good. But it's probably fine to just leave it as PHONY for this PR