|
10 | 10 | jobs: |
11 | 11 | release: |
12 | 12 | runs-on: ubuntu-latest |
| 13 | + outputs: |
| 14 | + release_tag: ${{ steps.set_tag.outputs.release_tag }} |
13 | 15 | steps: |
14 | 16 | - name: Checkout |
15 | 17 | uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 |
16 | 18 | - name: Release env |
| 19 | + id: set_tag |
17 | 20 | working-directory: ./tools |
18 | 21 | run: | |
19 | 22 | ./releaser/scripts/setghenv.sh |
| 23 | + echo "release_tag=${RELEASE_TAG}" >> $GITHUB_OUTPUT |
20 | 24 | - name: Create Release |
21 | 25 | uses: softprops/action-gh-release@da05d552573ad5aba039eaac05058a918a7bf631 |
22 | 26 | with: |
|
29 | 33 | LATEST_SDK_RELEASE=$(echo "${LATEST_SDK_TAG}" | cut -d '.' -f 1) |
30 | 34 | echo "tag: ${LATEST_SDK_TAG}, release: ${LATEST_SDK_RELEASE}" |
31 | 35 | curl -sSfL "https://proxy.golang.org/go.mongodb.org/atlas-sdk/${LATEST_SDK_RELEASE}/@v/${LATEST_SDK_TAG}.info" |
| 36 | + compliance: |
| 37 | + needs: release |
| 38 | + runs-on: ubuntu-latest |
| 39 | + env: |
| 40 | + SILKBOMB_IMG: ${{ vars.SILKBOMB_IMG }} |
| 41 | + RELEASE_TAG: ${{ needs.release.outputs.release_tag }} |
| 42 | + steps: |
| 43 | + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 |
| 44 | + with: |
| 45 | + ref: ${{ env.RELEASE_TAG }} |
| 46 | + - name: Generate PURLs and SBOM |
| 47 | + run: make gen-purls gen-sbom |
| 48 | + - name: Upload SBOM to Kondukto |
| 49 | + run: make upload-sbom |
| 50 | + env: |
| 51 | + KONDUKTO_TOKEN: ${{ secrets.KONDUKTO_TOKEN }} |
| 52 | + KONDUKTO_REPO: ${{ vars.KONDUKTO_REPO }} |
| 53 | + KONDUKTO_BRANCH_PREFIX: ${{ vars.KONDUKTO_BRANCH_PREFIX }} |
| 54 | + - name: Upload SBOM as release artifact |
| 55 | + uses: softprops/action-gh-release@da05d552573ad5aba039eaac05058a918a7bf631 |
| 56 | + with: |
| 57 | + files: compliance/sbom.json |
| 58 | + tag_name: ${{ env.RELEASE_TAG }} |
| 59 | + env: |
| 60 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 61 | + generate-ssdlc-report: |
| 62 | + needs: compliance |
| 63 | + runs-on: ubuntu-latest |
| 64 | + env: |
| 65 | + RELEASE_TAG: ${{ needs.release.outputs.release_tag }} |
| 66 | + steps: |
| 67 | + - name: Checkout |
| 68 | + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 |
| 69 | + - uses: ./.github/templates/run-script-and-commit |
| 70 | + with: |
| 71 | + script_call: | |
| 72 | + TAG="${{ env.RELEASE_TAG }}" |
| 73 | + VERSION="${TAG#v}" |
| 74 | + AUTHOR="${{ github.actor }}" |
| 75 | + export AUTHOR VERSION |
| 76 | + ./scripts/compliance/gen-ssdlc-report.sh |
| 77 | + file_to_commit: 'compliance/v*/ssdlc-compliance-*.md' |
| 78 | + commit_message: "chore: Update SSDLC report for ${{ env.RELEASE_TAG }}" |
| 79 | + apix_bot_pat: ${{ secrets.APIX_BOT_PAT }} |
| 80 | + remote: https://svc-apix-bot:${{ secrets.APIX_BOT_PAT }}@github.com/${{ github.repository }} |
| 81 | + gpg_private_key: ${{ secrets.APIX_BOT_GPG_PRIVATE_KEY }} |
| 82 | + passphrase: ${{ secrets.APIX_BOT_PASSPHRASE }} |
0 commit comments