-
Notifications
You must be signed in to change notification settings - Fork 0
98 lines (91 loc) · 3.76 KB
/
release-please.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Release Please
on:
workflow_dispatch:
push:
branches:
- main
jobs:
release-please:
runs-on: ubuntu-latest
outputs:
package-sdk-server-released: ${{ steps.release.outputs['pkgs/sdk/server--release_created'] }}
package-sdk-server-tag_name: ${{ steps.release.outputs['pkgs/sdk/server--tag_name'] }}
package-sdk-server-telemetry-released: ${{ steps.release.outputs['pkgs/telemetry--release_created'] }}
package-sdk-server-telemetry-tag_name: ${{ steps.release.outputs['pkgs/telemetry--tag_name'] }}
tag_name: ${{ steps.release.outputs.tag_name }}
steps:
- uses: google-github-actions/release-please-action@v4
id: release
with:
token: ${{ secrets.GITHUB_TOKEN }}
target-branch: ${{ github.ref_name }}
release-sdk-server:
runs-on: ubuntu-latest
needs: release-please
permissions:
id-token: write
contents: write
pull-requests: write
if: ${{ needs.release-please.outputs.package-sdk-server-released == 'true'}}
outputs:
hashes: ${{ steps.full-release.outputs.hashes }}
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/full-release
id: full-release
with:
workspace_path: 'pkgs/sdk/server'
project_file: 'pkgs/sdk/server/src/LaunchDarkly.ServerSdk.csproj'
test_project_file: 'pkgs/sdk/server/test/LaunchDarkly.ServerSdk.Tests.csproj'
build_output_path: 'pkgs/sdk/server/src/bin/Release/'
dll_name: 'LaunchDarkly.ServerSdk.dll'
dry_run: false
aws_role: ${{ vars.AWS_ROLE_ARN }}
token: ${{ secrets.GITHUB_TOKEN }}
release-sdk-server-provenance:
needs: ['release-please', 'release-sdk-server']
permissions:
actions: read
id-token: write
contents: write
uses: slsa-framework/slsa-github-generator/.github/workflows/[email protected]
with:
base64-subjects: "${{ needs.release-sdk-server.outputs.hashes }}"
upload-assets: true
upload-tag-name: ${{ needs.release-please.outputs.package-sdk-server-tag_name }}
provenance-name: ${{ format('LaunchDarkly.ServerSdk-{0}_provenance.intoto.jsonl', needs.release-please.outputs.package-sdk-server-tag_name) }}
release-telemetry:
runs-on: ubuntu-latest
needs: release-please
permissions:
id-token: write
contents: write
pull-requests: write
if: ${{ needs.release-please.outputs.package-sdk-server-telemetry-released == 'true'}}
outputs:
hashes: ${{ steps.full-release.outputs.hashes }}
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/full-release
id: full-release
with:
workspace_path: 'pkgs/telemetry'
project_file: 'pkgs/telemetry/src/LaunchDarkly.ServerSdk.Telemetry.csproj'
test_project_file: 'pkgs/telemetry/test/LaunchDarkly.ServerSdk.Telemetry.Tests.csproj'
build_output_path: 'pkgs/telemetry/src/bin/Release/'
dll_name: 'LaunchDarkly.ServerSdk.Telemetry.dll'
dry_run: false
aws_role: ${{ vars.AWS_ROLE_ARN }}
token: ${{ secrets.GITHUB_TOKEN }}
release-telemetry-provenance:
needs: ['release-please', 'release-telemetry']
permissions:
actions: read
id-token: write
contents: write
uses: slsa-framework/slsa-github-generator/.github/workflows/[email protected]
with:
base64-subjects: "${{ needs.release-telemetry.outputs.hashes }}"
upload-assets: true
upload-tag-name: ${{ needs.release-please.outputs.package-sdk-server-telemetry-tag_name }}
provenance-name: ${{ format('LaunchDarkly.ServerSdk.Telemetry-{0}_provenance.intoto.jsonl', needs.release-please.outputs.package-sdk-server-telemetry-tag_name) }}