diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a28c11a2..2cfe18b7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -98,17 +98,12 @@ jobs: fetch-depth: 0 - name: Make repo safe run: git config --global --add safe.directory /__w/SOARCA/SOARCA - - name: Make repo safe - run: git config --global --add safe.directory /__w/SOARCA/SOARCA - - - name: Install swaggo - run: go install github.com/swaggo/swag/cmd/swag@latest - - - name: Build swagger - run: swag init -o swaggerdocs - - name: Build sbom + - name: Build and sbom swagger run: | + go install github.com/swaggo/swag/cmd/swag@latest + go install github.com/CycloneDX/cyclonedx-gomod/cmd/cyclonedx-gomod@latest + swag init -o swaggerdocs mkdir -p sbom CGO_ENABLED=0 GOOS=linux GOARCH=amd64 cyclonedx-gomod app -json -licenses -output sbom/${BINARY_NAME}-${VERSION}-linux-amd64.bom.json CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 cyclonedx-gomod app -json -licenses -output sbom/${BINARY_NAME}-${VERSION}-darwin-amd64.bom.json