Skip to content

ci: switch from SLSA provenance to actions/attest with subject-path (… #124

ci: switch from SLSA provenance to actions/attest with subject-path (…

ci: switch from SLSA provenance to actions/attest with subject-path (… #124

name: Run Release Please
on:
push:
branches:
- main
jobs:
release-package:
runs-on: ubuntu-latest
permissions:
contents: write # Contents and pull-requests are for release-please to make releases.
pull-requests: write
outputs:
release-created: ${{ steps.release.outputs.release_created }}
steps:
- uses: googleapis/release-please-action@16a9c90856f42705d54a6fda1823352bdc62cf38 # v4.4.0
id: release
build-ruby-gem:
needs: ["release-package"]
if: ${{ needs.release-package.outputs.release-created == 'true' }}
uses: ./.github/workflows/build-gem.yml
with:
version: "3.2"
build-jruby-gem:
needs: ["release-package"]
if: ${{ needs.release-package.outputs.release-created == 'true' }}
uses: ./.github/workflows/build-gem.yml
with:
version: "jruby-9.4"
publish:
runs-on: ubuntu-latest
needs: ["release-package", "build-ruby-gem", "build-jruby-gem"]
if: ${{ needs.release-package.outputs.release-created == 'true' }}
permissions:
id-token: write # Needed if using OIDC to get release secrets.
contents: write # Contents and pull-requests are for release-please to make releases.
attestations: write # Needed for actions/attest.
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup
with:
version: "3.2"
install-dependencies: false
- uses: launchdarkly/gh-actions/actions/release-secrets@release-secrets-v1.2.0
name: "Get rubygems API key"
with:
aws_assume_role: ${{ vars.AWS_ROLE_ARN }}
ssm_parameter_pairs: "/production/common/releasing/rubygems/api_key = GEM_HOST_API_KEY"
- uses: ./.github/actions/build-docs
- uses: ./.github/actions/publish
id: publish
with:
dry_run: false
- uses: ./.github/actions/publish-docs
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Attest build provenance
uses: actions/attest@v4
with:
subject-path: 'launchdarkly-server-sdk-*.gem'