Skip to content

Create dependabot.yml #11

Create dependabot.yml

Create dependabot.yml #11

name: Dependecy-track
on:
push:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
repository: 0gis0/tour-of-heroes-dotnet-api
- name: Configure .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- name: Build with dotnet
run: dotnet build --configuration Release
- name: Install cdxgen
run: npm install -g @cyclonedx/cdxgen
- name: Generate SBOM and send to Dependecy-track server
run: |
pwd
FETCH_LICENSE=true cdxgen -o bom-1.4.json --spec-version 1.4 \
--server-url ${{ secrets.DEPENDENCYTRACK_HOSTNAME }} \
--api-key ${{ secrets.DEPENDENCYTRACK_APIKEY }} \
--project-name tour-of-heroes-dotnet-from-gh-actions \
--project-version 1.0.0 \
--auto-create