From e6591d114383aeb381a51fd9edda1d3c5254d64d Mon Sep 17 00:00:00 2001 From: Elaine Laguerta Date: Mon, 27 May 2024 11:30:36 -0700 Subject: [PATCH] test --- .github/workflows/fossa-check-env.yml | 9 +++++++-- .github/workflows/fossa-default.yml | 3 ++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/fossa-check-env.yml b/.github/workflows/fossa-check-env.yml index 214267e..bda80f5 100644 --- a/.github/workflows/fossa-check-env.yml +++ b/.github/workflows/fossa-check-env.yml @@ -4,14 +4,19 @@ on: secrets: FOSSA_API_KEY: required: false + outputs: + HAS_FOSSA_API_KEY: + description: "True if FOSSA API key is available." + value: ${{ jobs.check_env.outputs.check }} jobs: check_env: runs-on: ubuntu-latest env: HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }} + FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }} + outputs: + check: ${{ steps.check-fossa-api-key.outputs.check }} steps: - id: check-fossa-api-key run: echo "check=$HAS_FOSSA_API_KEY" >> "$GITHUB_OUTPUT" - outputs: - HAS_FOSSA_API_KEY: ${{ steps.check-fossa-api-key.outputs.check }} diff --git a/.github/workflows/fossa-default.yml b/.github/workflows/fossa-default.yml index 1f07162..3a83e21 100644 --- a/.github/workflows/fossa-default.yml +++ b/.github/workflows/fossa-default.yml @@ -2,11 +2,12 @@ name: FOSSA CLI Analysis - Default on: pull_request: branches: [ $default-branch ] - workflow_call: jobs: check_env: uses: newrelic-csec/.github/.github/workflows/fossa-check-env.yml@reusable + secrets: + FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }} fossa: needs: check_env