Use a light background for pod logs in the Light theme #2164
Workflow file for this run
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
| name: NPM Licenses | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - "*" | |
| workflow_dispatch: {} | |
| permissions: | |
| contents: read | |
| jobs: | |
| licenses: | |
| name: licenses | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - runs-on: ubuntu-24.04-arm | |
| arch: arm64 | |
| runs-on: ${{ matrix.runs-on }} | |
| timeout-minutes: 60 | |
| env: | |
| DO_NOT_TRACK: "1" | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v7 | |
| - name: Setup node | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: .nvmrc | |
| package-manager-cache: false | |
| - name: Setup pnpm | |
| run: corepack enable | |
| - name: Get pnpm cache directory | |
| shell: bash | |
| run: echo "pnpm_cache_dir=$(pnpm store path)" >> ${GITHUB_ENV} | |
| - name: Use pnpm cache | |
| uses: actions/cache@v5 | |
| with: | |
| path: ${{ env.pnpm_cache_dir }} | |
| key: ${{ matrix.runs-on }}-${{ matrix.arch }}-node-${{ hashFiles('pnpm-lock.yaml') }} | |
| restore-keys: | | |
| ${{ matrix.runs-on }}-${{ matrix.arch }}-node- | |
| - name: Install pnpm dependencies | |
| id: install-pnpm | |
| run: timeout 300 pnpm install --color=always --prefer-offline --frozen-lockfile | |
| continue-on-error: true | |
| - name: Install pnpm dependencies (retry) | |
| if: steps.install-pnpm.outcome == 'failure' | |
| run: timeout 300 pnpm install --color=always --prefer-offline --frozen-lockfile | |
| - name: List licenses | |
| run: pnpm licenses list --json > licenses.json | |
| - name: Validate licenses | |
| run: yq -pj -oy 'pick((keys) - (pick(env(allowed_licenses)) | keys))' licenses.json > disallowed_licenses.yaml | |
| env: | |
| allowed_licenses: |- | |
| - (Apache-2.0 OR MPL-1.1) | |
| - (BSD-3-Clause OR GPL-2.0) | |
| - (MIT AND Zlib) | |
| - (MIT OR CC0-1.0) | |
| - (MIT OR GPL-3.0-or-later) | |
| - (MPL-2.0 OR Apache-2.0) | |
| - 0BSD | |
| - Apache-2.0 | |
| - BlueOak-1.0.0 | |
| - BSD-2-Clause | |
| - BSD-3-Clause | |
| - CC-BY-4.0 | |
| - CC0 | |
| - CC0-1.0 | |
| - ISC | |
| - LGPL-3.0-or-later | |
| - MIT | |
| - MIT-0 | |
| - MPL-2.0 | |
| - Python-2.0 | |
| - Unlicense | |
| - WTFPL | |
| - WTFPL OR ISC | |
| - name: Fail if disallowed licenses found | |
| run: |- | |
| if [ $(yq 'keys|length' disallowed_licenses.yaml) -gt 0 ]; then | |
| echo "Disallowed licenses found:" | |
| yq -C disallowed_licenses.yaml | |
| exit 1 | |
| else | |
| echo "No disallowed licenses found." | |
| fi |