Skip to content

Commit

Permalink
Merge pull request #52 from newrelic/skip-forks
Browse files Browse the repository at this point in the history
Skip FOSSA for forks
  • Loading branch information
elaguerta-nr authored May 17, 2024
2 parents 44575ce + 9eff393 commit 8ee98d8
Show file tree
Hide file tree
Showing 6 changed files with 72 additions and 18 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/fossa-caos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- uses: actions/checkout@v3
- name: Give GitHub Actions access to private crates
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/fossa-default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- uses: actions/checkout@v3
- id: fossa-list-targets
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/fossa-elixir.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- uses: actions/checkout@v3
- uses: erlef/setup-beam@v1
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/fossa-gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- name: Checkout this repo
uses: actions/checkout@v4
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/fossa-ruby-bundler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
Expand Down
15 changes: 12 additions & 3 deletions .github/workflows/fossa-scala.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,26 @@ on:
workflow_dispatch:

jobs:
check_env:
runs-on: ubuntu-latest
env:
HAS_FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY != '' }}
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 }}

fossa:
needs: check_env
if: ${{ needs.check_env.HAS_FOSSA_API_KEY }}
runs-on: ubuntu-latest
env:
FOSSA_API_KEY: ${{secrets.FOSSA_API_KEY}}
ORG: ${{ github.repository_owner }}
REPO: ${{ github.repository }}
CUSTOM_PROPS_PAT: ${{ secrets.FOSSA_PAT }}

strategy:
fail-fast: false

steps:
- uses: actions/checkout@v3
- name: Download newrelic.jar
Expand Down

0 comments on commit 8ee98d8

Please sign in to comment.