diff --git a/.github/workflows/build_documentation.yml b/.github/workflows/build_documentation.yml index 34bfe1f..96e9c8c 100644 --- a/.github/workflows/build_documentation.yml +++ b/.github/workflows/build_documentation.yml @@ -8,8 +8,12 @@ on: - 'v[0-9]+.[0-9]+.[0-9]+' workflow_dispatch: +permissions: {} + jobs: build_documentation: + permissions: + contents: read runs-on: ubuntu-22.04 env: PR_NUMBER: ${{ github.event.number }} @@ -17,14 +21,14 @@ jobs: PR_CLONE_URL: ${{ github.event.pull_request.head.repo.clone_url }} steps: - - uses: actions/checkout@v7 - - uses: actions/setup-node@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 with: node-version: '20' cache-dependency-path: "kit/package-lock.json" - name: Set up Python - uses: actions/setup-python@v7 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: '3.11' diff --git a/.github/workflows/build_pr_documentation.yml b/.github/workflows/build_pr_documentation.yml index 9def90e..f94e139 100644 --- a/.github/workflows/build_pr_documentation.yml +++ b/.github/workflows/build_pr_documentation.yml @@ -9,8 +9,12 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} cancel-in-progress: true +permissions: {} + jobs: build_documentation: + permissions: + contents: read runs-on: ubuntu-22.04 env: COMMIT_SHA: ${{ github.event.pull_request.head.sha }} @@ -19,14 +23,14 @@ jobs: PR_CLONE_URL: ${{ github.event.pull_request.head.repo.clone_url }} steps: - - uses: actions/checkout@v7 - - uses: actions/setup-node@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 with: node-version: '20' cache-dependency-path: "kit/package-lock.json" - name: Set up Python - uses: actions/setup-python@v7 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: '3.11' @@ -57,7 +61,7 @@ jobs: echo ${{ env.COMMIT_SHA }} > ./commit_sha echo ${{ github.event.number }} > ./pr_number - - uses: actions/upload-artifact@v7 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: doc-build-artifact path: executorch-doc-build/ diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml index d123d93..63ddaf6 100644 --- a/.github/workflows/quality.yml +++ b/.github/workflows/quality.yml @@ -12,8 +12,12 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} cancel-in-progress: true +permissions: {} + jobs: quality: + permissions: + contents: read runs-on: ubuntu-22.04 steps: diff --git a/.github/workflows/test_models.yml b/.github/workflows/test_models.yml index 7096f07..911b6c4 100644 --- a/.github/workflows/test_models.yml +++ b/.github/workflows/test_models.yml @@ -10,13 +10,17 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} cancel-in-progress: true +permissions: {} + jobs: discover-tests: + permissions: + contents: read runs-on: ubuntu-22.04 outputs: model_names: ${{ steps.set-matrix.outputs.model_names }} steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: Find model tests id: set-matrix run: | @@ -29,6 +33,8 @@ jobs: echo "$MODEL_NAMES" | tr ',' '\n' | sort | awk '{print "- " $0}' run-tests: + permissions: + contents: read needs: discover-tests strategy: fail-fast: false @@ -48,9 +54,9 @@ jobs: env: MODEL_NAME: ${{ matrix.test-modeling }} steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: Setup Python ${{ matrix.python-version }} - uses: actions/setup-python@v7 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: ${{ matrix.python-version }} - name: Free disk and increase swap space diff --git a/.github/workflows/test_models_nightly.yml b/.github/workflows/test_models_nightly.yml index 941843d..3e713ce 100644 --- a/.github/workflows/test_models_nightly.yml +++ b/.github/workflows/test_models_nightly.yml @@ -11,13 +11,17 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} cancel-in-progress: true +permissions: {} + jobs: discover-tests: + permissions: + contents: read runs-on: ubuntu-22.04 outputs: model_names: ${{ steps.set-matrix.outputs.model_names }} steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: Find model tests id: set-matrix run: | @@ -28,6 +32,8 @@ jobs: echo "$MODEL_NAMES" | tr ',' '\n' | sort | awk '{print "- " $0}' run-tests: + permissions: + contents: read needs: discover-tests strategy: fail-fast: false @@ -44,9 +50,9 @@ jobs: env: MODEL_NAME: ${{ matrix.test-modeling }} steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: Setup Python ${{ matrix.python-version }} - uses: actions/setup-python@v7 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: ${{ matrix.python-version }} - name: Free disk and increase swap space