|
29 | 29 | attestations: "git github environment"
|
30 | 30 | command: go vet ./...
|
31 | 31 |
|
32 |
| - # --ignore DL3002 |
33 |
| - lint: |
34 |
| - uses: ./.github/workflows/witness.yml |
35 |
| - with: |
36 |
| - pull_request: ${{ github.event_name == 'pull_request' }} |
37 |
| - step: lint |
38 |
| - pre-command-attestations: "git github environment" |
39 |
| - attestations: "git github environment" |
40 |
| - pre-command: | |
41 |
| - curl -sSfL https://github.com/hadolint/hadolint/releases/download/v2.12.0/hadolint-Linux-x86_64 -o /usr/local/bin/hadolint && \ |
42 |
| - chmod +x /usr/local/bin/hadolint |
43 |
| - command: hadolint -f sarif Dockerfile > hadolint.sarif |
44 |
| - artifact-upload-name: hadolint.sarif |
45 |
| - artifact-upload-path: hadolint.sarif |
46 |
| - |
47 | 32 | unit-test:
|
48 |
| - needs: [ fmt, vet, lint ] |
| 33 | + needs: [ fmt, vet ] |
49 | 34 | uses: ./.github/workflows/witness.yml
|
50 | 35 | with:
|
51 | 36 | pull_request: ${{ github.event_name == 'pull_request' }}
|
|
55 | 40 | artifact-upload-name: cover.out
|
56 | 41 | artifact-upload-path: cover.out
|
57 | 42 |
|
58 |
| - sast: |
59 |
| - needs: [ fmt, vet, lint ] |
60 |
| - uses: ./.github/workflows/witness.yml |
61 |
| - with: |
62 |
| - pull_request: ${{ github.event_name == 'pull_request' }} |
63 |
| - step: sast |
64 |
| - pre-command-attestations: "git github environment" |
65 |
| - attestations: "git github environment" |
66 |
| - pre-command: python3 -m pip install semgrep==1.45.0 |
67 |
| - command: semgrep scan --config auto ./ --sarif -o semgrep.sarif |
68 |
| - artifact-upload-name: semgrep.sarif |
69 |
| - artifact-upload-path: semgrep.sarif |
70 |
| - |
71 | 43 | build:
|
72 |
| - needs: [ unit-test, sast ] |
| 44 | + needs: [ unit-test ] |
73 | 45 | uses: ./.github/workflows/witness.yml
|
74 | 46 | with:
|
75 | 47 | pull_request: ${{ github.event_name == 'pull_request' }}
|
|
78 | 50 | command: go build -o bin/software main.go
|
79 | 51 |
|
80 | 52 | build-image:
|
81 |
| - needs: [ unit-test, sast ] |
| 53 | + needs: [ unit-test ] |
82 | 54 | runs-on: ubuntu-latest
|
83 | 55 |
|
84 | 56 | permissions:
|
@@ -128,35 +100,3 @@ jobs:
|
128 | 100 |
|
129 | 101 | outputs:
|
130 | 102 | tags: ${{ steps.meta.outputs.tags }}
|
131 |
| - |
132 |
| - generate-sbom: |
133 |
| - needs: build-image |
134 |
| - uses: ./.github/workflows/witness.yml |
135 |
| - with: |
136 |
| - pull_request: ${{ github.event_name == 'pull_request' }} |
137 |
| - step: generate-sbom |
138 |
| - pre-command-attestations: "git github environment" |
139 |
| - attestations: "git github environment sbom" |
140 |
| - artifact-download: image.tar |
141 |
| - pre-command: | |
142 |
| - curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh | sh -s -- -b /usr/local/bin |
143 |
| - command: | |
144 |
| - syft packages docker-archive:/tmp/image.tar --source-name=pkg:oci/testifysec/swf -o cyclonedx-json --file sbom.cdx.json |
145 |
| - artifact-upload-name: sbom.cdx.json |
146 |
| - artifact-upload-path: sbom.cdx.json |
147 |
| - |
148 |
| - secret-scan: |
149 |
| - needs: build-image |
150 |
| - uses: ./.github/workflows/witness.yml |
151 |
| - with: |
152 |
| - pull_request: ${{ github.event_name == 'pull_request' }} |
153 |
| - step: secret-scan |
154 |
| - pre-command-attestations: "git github environment" |
155 |
| - attestations: "git github environment" |
156 |
| - artifact-download: image.tar |
157 |
| - pre-command: | |
158 |
| - curl -sSfL https://raw.githubusercontent.com/trufflesecurity/trufflehog/main/scripts/install.sh | sh -s -- -b /usr/local/bin |
159 |
| - command: | |
160 |
| - trufflehog docker --image=file:///tmp/image.tar -j > trufflehog.json |
161 |
| - artifact-upload-name: trufflehog.json |
162 |
| - artifact-upload-path: trufflehog.json |
0 commit comments