2424
2525env :
2626 TF_VAR_aws_access_key_id : ${{ secrets.INTEG_TEST_AWS_KEY_ID }}
27- TF_VAR_aws_secret_access_key : ${{ secrets.INTEG_TEST_AWS_KEY_SECRET }}
27+ TF_VAR_aws_secret_access_key : ${{ secrets.INTEG_TEST_AWS_KEY_SECRET }}
28+ GH_PAGES_BRANCH : gh-pages
29+ MAX_BENCHMARKS_TO_KEEP : 100
30+ COMMIT_USER : Github Actions
31+ 2832
2933jobs :
3034 get-testing-version :
@@ -132,10 +136,6 @@ jobs:
132136 needs : [get-testing-version, run-perf-test]
133137 steps :
134138 - uses : actions/checkout@v2
135- - uses : actions/checkout@v2
136- with :
137- ref : gh-pages
138- path : gh-pages
139139
140140 - name : Setup Python
141141@@ -150,29 +150,24 @@ jobs:
150150
151151 - name : Produce performance report
152152 run : python e2etest/get-performance-model-table.py ${{ needs.get-testing-version.outputs.testing_version }}
153-
154- - name : Copy performance report
155- run : rsync -avv performance-report.md gh-pages/benchmark/report.md
156-
157- - name : Copy performance data
158- run : rsync -avv performance-data.json gh-pages/benchmark/data
159153
160154 - name : Store benchmark result
161- uses : benchmark-action /github-action-benchmark@v1
155+ uses : jefchien /github-action-benchmark@v1.11.12-alpha2
162156 with :
163157 tool : " customSmallerIsBetter"
164158 output-file-path : performance-data.json
165- external -data-json -path : gh-pages/ benchmark/data/previous-benchmark-data.json
166- benchmark-data-dir-path : gh-pages/benchmark/trend
167- skip-fetch- gh-pages: true
159+ benchmark -data-dir -path : benchmark/trend
160+ max-items-in-chart : ${{ env.MAX_BENCHMARKS_TO_KEEP }}
161+ gh-pages-branch : ${{ env.GH_PAGES_BRANCH }}
168162 github-token : ${{ secrets.GITHUB_TOKEN }}
163+ commit-sha : ${{ github.event.inputs.sha }}
169164 auto-push : false
170165
171166 - name : Commit to gh-pages branch
172- uses : stefanzweifel/git-auto-commit-action@v4
173- with :
174- commit_message : " Update benchmarking "
175- commit_options : " --amend "
176- branch : gh-pages
177- repository : gh-pages
178- file_pattern : gh-pages/benchmark/report.md gh-pages/benchmark/data/* gh-pages/benchmark/trend/*
167+ run : |
168+ git switch ${{ env.GH_PAGES_BRANCH }}
169+ rsync -avv performance-report.md benchmark/report.md
170+ rsync -avv performance-data.json benchmark/data/
171+ git add benchmark/data/* benchmark/report.md
172+ git -c user.name="${{ env.COMMIT_USER }}" -c user.email="${{ env.COMMIT_EMAIL }}" commit --amend --reset-author -m "Update benchmarking for ${{ github.event.inputs.sha }}"
173+ git push origin ${{ env.GH_PAGES_BRANCH }}:${{ env.GH_PAGES_BRANCH }}
0 commit comments