Skip to content

Commit 9544b43

Browse files
committed
ci: set up perf workflow job and create initial workflow
Set up the initial workflow to build upon.
1 parent 26a817c commit 9544b43

File tree

4 files changed

+591
-29
lines changed

4 files changed

+591
-29
lines changed

.github/workflows/perf.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: Performance Tracking
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
permissions:
9+
contents: 'read'
10+
id-token: 'write'
11+
12+
defaults:
13+
run:
14+
shell: bash
15+
16+
jobs:
17+
list:
18+
timeout-minutes: 3
19+
runs-on: ubuntu-latest
20+
outputs:
21+
workflows: ${{ steps.workflows.outputs.workflows }}
22+
steps:
23+
- name: Initialize environment
24+
uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@53fb7c37cf14343f14ed79e2fefbbb2489ead4ee
25+
- name: Install node modules
26+
run: yarn install --frozen-lockfile
27+
- id: workflows
28+
run: echo "workflows=$(yarn ng-dev perf workflows --list)" >> "$GITHUB_OUTPUT"
29+
30+
workflow:
31+
timeout-minutes: 30
32+
runs-on: ubuntu-latest
33+
needs: list
34+
strategy:
35+
matrix:
36+
workflow: ${{ fromJSON(needs.list.outputs.workflows) }}
37+
steps:
38+
- name: Initialize environment
39+
uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@53fb7c37cf14343f14ed79e2fefbbb2489ead4ee
40+
- name: Setup Bazel
41+
uses: angular/dev-infra/github-actions/bazel/setup@53fb7c37cf14343f14ed79e2fefbbb2489ead4ee
42+
- name: Install node modules
43+
run: yarn install --frozen-lockfile
44+
# We utilize the google-github-actions/auth action to allow us to get an active credential using workflow
45+
# identity federation. This allows us to request short lived credentials on demand, rather than storing
46+
# credentials in secrets long term. More information can be found at:
47+
# https://docs.github.com/en/actions/security-for-github-actions/security-hardening-your-deployments/configuring-openid-connect-in-google-cloud-platform
48+
- uses: 'google-github-actions/auth@v2'
49+
with:
50+
project_id: 'internal-200822'
51+
workload_identity_provider: 'projects/823469418460/locations/global/workloadIdentityPools/measurables-tracking/providers/angular'
52+
service_account: '[email protected]'
53+
- run: yarn ng-dev perf workflows --name ${{ matrix.workflow }} --commit-sha ${{github.sha}}

.ng-dev/dx-perf-workflows.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
workflows:
2+
build-core:
3+
name: Build core
4+
prepare:
5+
- bazel clean
6+
workflow:
7+
- bazel build //src/material/core:core

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@
7979
"@angular/cli": "^19.0.0",
8080
"@angular/compiler-cli": "^19.0.0",
8181
"@angular/localize": "^19.0.0",
82-
"@angular/ng-dev": "https://github.com/angular/dev-infra-private-ng-dev-builds.git#36946be4df61f6549ae3829c026022e47674eae2",
82+
"@angular/ng-dev": "https://github.com/angular/dev-infra-private-ng-dev-builds.git#0692d4d0707f3a40f862e761eaf0be3b693326df",
8383
"@angular/platform-browser-dynamic": "^19.0.0",
8484
"@angular/platform-server": "^19.0.0",
8585
"@angular/router": "^19.0.0",

0 commit comments

Comments
 (0)