|
66 | 66 | with: |
67 | 67 | fail-on-severity: high |
68 | 68 |
|
69 | | - release-artifact: |
70 | | - name: Build, attest, and archive release artifact |
71 | | - if: startsWith(github.ref, 'refs/tags/v') |
72 | | - runs-on: ubuntu-24.04 |
73 | | - timeout-minutes: 20 |
74 | | - permissions: |
75 | | - contents: read |
76 | | - id-token: write |
77 | | - attestations: write |
78 | | - steps: |
79 | | - - name: Check out source |
80 | | - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 |
81 | | - |
82 | | - - name: Set up Java |
83 | | - uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1 |
84 | | - with: |
85 | | - distribution: temurin |
86 | | - java-version: "17" |
87 | | - cache: gradle |
88 | | - |
89 | | - - name: Generate and verify release SBOM |
90 | | - run: ./gradlew --no-daemon --max-workers=2 verifyReleaseSbom |
91 | | - |
92 | | - - name: Resolve release APK |
93 | | - id: release-apk |
94 | | - run: | |
95 | | - apk="$(find app/build/outputs/apk/release -maxdepth 1 -type f -name 'app-release*.apk' -print -quit)" |
96 | | - test -n "$apk" |
97 | | - echo "path=$apk" >> "$GITHUB_OUTPUT" |
98 | | -
|
99 | | - - name: Archive APK, SBOM, provenance, and hash |
100 | | - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 |
101 | | - with: |
102 | | - name: callshield-release-${{ github.ref_name }} |
103 | | - if-no-files-found: error |
104 | | - path: | |
105 | | - ${{ steps.release-apk.outputs.path }} |
106 | | - app/build/outputs/apk/release/app-release*.cdx.json |
107 | | - app/build/outputs/apk/release/app-release*.provenance.json |
108 | | - app/build/outputs/apk/release/app-release*.sha256 |
109 | | -
|
110 | | - - name: Create GitHub OIDC provenance attestation |
111 | | - uses: actions/attest-build-provenance@c074443f1aee8d4aeeae555aebba3282517141b2 # v2.2.3 |
112 | | - with: |
113 | | - subject-path: ${{ steps.release-apk.outputs.path }} |
114 | | - |
115 | 69 | dependency-submission: |
116 | 70 | name: Publish resolved Gradle dependency graph |
117 | 71 | if: github.event_name != 'pull_request' |
|
0 commit comments