Skip to content
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

Fix zizmor warnings in github actions #614

Merged
merged 1 commit into from
Sep 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions .github/workflows/build-docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,13 @@ on:
- 'runners/**'
- 'cryptography-linux/**'

permissions:
contents: read
packages: write

jobs:
# Build containers for x86
build:
runs-on: ${{ matrix.IMAGE.RUNNER }}
permissions:
contents: read
packages: write

strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -63,6 +62,8 @@ jobs:
name: "${{ matrix.IMAGE.TAG_NAME }}"
steps:
- uses: actions/[email protected]
with:
persist-credentials: false
- run: |
source ./staticnode/node-version.sh
arch=$(echo "${{ runner.arch }}" | tr '[:upper:]' '[:lower:]')
Expand All @@ -74,7 +75,7 @@ jobs:
run: docker pull ghcr.io/pyca/${{ matrix.IMAGE.TAG_NAME }} || true
if: github.event_name != 'schedule' && github.event_name != 'workflow_dispatch'
- name: Build image
run: docker build --pull --cache-from ghcr.io/pyca/${{ matrix.IMAGE.TAG_NAME }} -t ghcr.io/pyca/${{ matrix.IMAGE.TAG_NAME }} ${{ matrix.IMAGE.DOCKERFILE_PATH }} ${{ matrix.IMAGE.BUILD_ARGS }} --build-arg NODE_ARCH_RELEASE=${{ env.NODE_ARCH_RELEASE }}
run: docker build --pull --cache-from ghcr.io/pyca/${{ matrix.IMAGE.TAG_NAME }} -t ghcr.io/pyca/${{ matrix.IMAGE.TAG_NAME }} ${{ matrix.IMAGE.DOCKERFILE_PATH }} ${{ matrix.IMAGE.BUILD_ARGS }} --build-arg "NODE_ARCH_RELEASE=${NODE_ARCH_RELEASE}"
- name: Login to docker
run: 'docker login -u "$DOCKER_USERNAME" -p "$DOCKER_PASSWORD" ghcr.io'
env:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/build-macos-openssl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ jobs:
name: "Build OpenSSL for macOS (${{ matrix.ARCH.NAME }})"
steps:
- uses: actions/[email protected]
with:
persist-credentials: false
- name: Download OpenSSL
run: |
source ./cryptography-linux/openssl-version.sh
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/build-static-node.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
name: Build Static Node.js Container
permissions:
contents: read
packages: write

on:
pull_request:
Expand All @@ -19,6 +16,9 @@ jobs:
build:
name: Build node.js
runs-on: ${{ matrix.IMAGE.RUNNER }}
permissions:
contents: read
packages: write
strategy:
fail-fast: false
matrix:
Expand All @@ -27,6 +27,8 @@ jobs:
- {RUNNER: [self-hosted, Linux, ARM64], MANYLINUX_ARCH: "aarch64"}
steps:
- uses: actions/[email protected]
with:
persist-credentials: false
- name: Set Node.js version
run: |
source ./staticnode/node-version.sh
Expand All @@ -50,5 +52,5 @@ jobs:
DOCKER_PASSWORD: ${{ secrets.GITHUB_TOKEN }}
if: (github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/main'
- name: Push image
run: docker push ghcr.io/pyca/static-nodejs-${{ env.NODE_ARCH }}:${{ env.NODE_VERSION }}
run: docker push "ghcr.io/pyca/static-nodejs-${NODE_ARCH}:${NODE_VERSION}"
if: (github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.ref == 'refs/heads/main'
2 changes: 2 additions & 0 deletions .github/workflows/build-windows-openssl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ jobs:
name: "Build OpenSSL for ${{ matrix.ARCH }} on MSVC 2022"
steps:
- uses: actions/[email protected]
with:
persist-credentials: false
- run: choco install -y nasm winrar
- name: Export OpenSSL version
run: |
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/terraform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
persist-credentials: false
- run: terraform -chdir=terraform/ fmt -check
- run: terraform -chdir=terraform/ init -backend=false
# Need to have a values.yaml for validate to pass.
Expand Down