mirror of
				https://github.com/mkuf/prind.git
				synced 2025-10-31 02:16:06 +01:00 
			
		
		
		
	ci: add zizmor workflow (#183)
* ci: add zizmor workflow w/ config * update workflows according to zizmor suggestions
This commit is contained in:
		| @@ -16,6 +16,8 @@ jobs: | |||||||
|       apps: ${{ steps.filter.outputs.changes }} |       apps: ${{ steps.filter.outputs.changes }} | ||||||
|     steps: |     steps: | ||||||
|       - uses: actions/checkout@v4 |       - uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - uses: dorny/paths-filter@v3 |       - uses: dorny/paths-filter@v3 | ||||||
|         id: filter |         id: filter | ||||||
|         with: |         with: | ||||||
| @@ -39,6 +41,8 @@ jobs: | |||||||
|     steps: |     steps: | ||||||
|       - name: "[prind] checkout" |       - name: "[prind] checkout" | ||||||
|         uses: actions/checkout@v4 |         uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - name: "[prind] set up build environment" |       - name: "[prind] set up build environment" | ||||||
|         uses: ./.github/actions/image-build-common |         uses: ./.github/actions/image-build-common | ||||||
|       - name: "[docker] login" |       - name: "[docker] login" | ||||||
|   | |||||||
| @@ -16,6 +16,8 @@ jobs: | |||||||
|     steps: |     steps: | ||||||
|       - name: "[prind] checkout" |       - name: "[prind] checkout" | ||||||
|         uses: actions/checkout@v4 |         uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - name: "[prind] set up build environment" |       - name: "[prind] set up build environment" | ||||||
|         uses: ./.github/actions/image-build-common |         uses: ./.github/actions/image-build-common | ||||||
|       - name: "[docker] login" |       - name: "[docker] login" | ||||||
|   | |||||||
							
								
								
									
										4
									
								
								.github/workflows/image-build-review.yaml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								.github/workflows/image-build-review.yaml
									
									
									
									
										vendored
									
									
								
							| @@ -16,6 +16,8 @@ jobs: | |||||||
|       apps: ${{ steps.filter.outputs.changes }} |       apps: ${{ steps.filter.outputs.changes }} | ||||||
|     steps: |     steps: | ||||||
|       - uses: actions/checkout@v4 |       - uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - uses: dorny/paths-filter@v3 |       - uses: dorny/paths-filter@v3 | ||||||
|         id: filter |         id: filter | ||||||
|         with: |         with: | ||||||
| @@ -56,6 +58,8 @@ jobs: | |||||||
|     steps: |     steps: | ||||||
|       - name: "[prind] checkout" |       - name: "[prind] checkout" | ||||||
|         uses: actions/checkout@v4 |         uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - name: "[prind] set up build environment" |       - name: "[prind] set up build environment" | ||||||
|         uses: ./.github/actions/image-build-common |         uses: ./.github/actions/image-build-common | ||||||
|       - name: "[prind] build" |       - name: "[prind] build" | ||||||
|   | |||||||
							
								
								
									
										4
									
								
								.github/workflows/image-docs-publish.yaml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								.github/workflows/image-docs-publish.yaml
									
									
									
									
										vendored
									
									
								
							| @@ -17,6 +17,8 @@ jobs: | |||||||
|       apps: ${{ steps.filter.outputs.changes }} |       apps: ${{ steps.filter.outputs.changes }} | ||||||
|     steps: |     steps: | ||||||
|       - uses: actions/checkout@v4 |       - uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - uses: dorny/paths-filter@v3 |       - uses: dorny/paths-filter@v3 | ||||||
|         id: filter |         id: filter | ||||||
|         with: |         with: | ||||||
| @@ -42,6 +44,8 @@ jobs: | |||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     steps: |     steps: | ||||||
|       - uses: actions/checkout@v4 |       - uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - name: "Update Docker Hub Description" |       - name: "Update Docker Hub Description" | ||||||
|         uses: peter-evans/dockerhub-description@v4 |         uses: peter-evans/dockerhub-description@v4 | ||||||
|         with: |         with: | ||||||
|   | |||||||
							
								
								
									
										2
									
								
								.github/workflows/pr-yamllint.yaml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/workflows/pr-yamllint.yaml
									
									
									
									
										vendored
									
									
								
							| @@ -7,5 +7,7 @@ jobs: | |||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     steps: |     steps: | ||||||
|       - uses: actions/checkout@v4 |       - uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|       - name: Run yamllint |       - name: Run yamllint | ||||||
|         uses: reviewdog/action-yamllint@v1 |         uses: reviewdog/action-yamllint@v1 | ||||||
|   | |||||||
							
								
								
									
										31
									
								
								.github/workflows/zizmor.yaml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								.github/workflows/zizmor.yaml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,31 @@ | |||||||
|  | name: GitHub Actions Security Analysis with zizmor 🌈 | ||||||
|  |  | ||||||
|  | on: | ||||||
|  |   push: | ||||||
|  |     branches: ["main"] | ||||||
|  |   pull_request: | ||||||
|  |     branches: ["**"] | ||||||
|  |  | ||||||
|  | jobs: | ||||||
|  |   zizmor: | ||||||
|  |     name: zizmor latest via PyPI | ||||||
|  |     runs-on: ubuntu-latest | ||||||
|  |     permissions: | ||||||
|  |       security-events: write | ||||||
|  |       actions: read | ||||||
|  |     steps: | ||||||
|  |       - name: Checkout repository | ||||||
|  |         uses: actions/checkout@v4 | ||||||
|  |         with: | ||||||
|  |           persist-credentials: false | ||||||
|  |       - name: Install the latest version of uv | ||||||
|  |         uses: astral-sh/setup-uv@v4 | ||||||
|  |       - name: Run zizmor 🌈 | ||||||
|  |         run: uvx zizmor --format sarif . > results.sarif | ||||||
|  |         env: | ||||||
|  |           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||||||
|  |       - name: Upload SARIF file | ||||||
|  |         uses: github/codeql-action/upload-sarif@v3 | ||||||
|  |         with: | ||||||
|  |           sarif_file: results.sarif | ||||||
|  |           category: zizmor | ||||||
							
								
								
									
										5
									
								
								zizmor.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								zizmor.yml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | |||||||
|  | rules: | ||||||
|  |   template-injection: | ||||||
|  |     ignore: | ||||||
|  |       - image-build-and-publish-push.yaml:53:9 | ||||||
|  |       - image-build-review.yaml:65:9 | ||||||
		Reference in New Issue
	
	Block a user