Add compilation cache in react native CI#15329
Conversation
| - name: CACHE_DIR | ||
| type: string | ||
|
|
||
| - name: ChangeEveryCommit |
There was a problem hiding this comment.
nit: could the parameter names have a uniform casing convention? e.g., either ParameterName or PARAMETER_NAME
There was a problem hiding this comment.
Thanks. changed CACHE_DIR to CacheDir
| - script: | | ||
| brew install ccache | ||
| which ccache || brew install ccache | ||
| echo "##vso[task.prependpath]/usr/local/opt/ccache/libexec" |
There was a problem hiding this comment.
is it possible that ccache is installed in a different directory? with the which ccache call above, it seems like it could be.
if it is, would the path /usr/local/opt/ccache/libexec still be the right one?
There was a problem hiding this comment.
In CI, it's unlikely.
There was a problem hiding this comment.
so if there is an existing ccache, we assume it is a brew installation of ccache.
maybe something like brew list ccache &> /dev/null || brew install ccache above then?
There was a problem hiding this comment.
It‘s a big risk that there's any unknown installation in build machine.
There was a problem hiding this comment.
It‘s a big risk that there's any unknown installation in build machine.
sorry, I didn't quite understand this point. could you please elaborate?
There was a problem hiding this comment.
Unknow installation pose security risk.
https://en.wikipedia.org/wiki/2020_United_States_federal_government_data_breach
On May 12, 2021, President Biden issued an [Executive Order on Improving the Nations Cybersecurity](https://www.whitehouse.gov/briefing-room/presidential-actions/2021/05/12/executive-order-on-improving-the-nations-cybersecurity/). It put compliance requirements on build system and software development lifecycle of the software provided to the U.S. government. At Microsoft, all customer facing cloud services and all the latest released versions of our on-prem products will need to conform with the Executive Order.
There was a problem hiding this comment.
I got the part that unknown installations are a security risk. I didn't understand how it's being mitigated. and aren't we using hosted Mac agents which have known installed software?
…zhanyi/reactcache
### Description It seems like #15329 re-worked some jobs in `react-native-ci.yml` into stages. When this template is used from within `npm-packaging-pipeline.yml`, there is problem in that there is a stage that contains multiple stages as jobs. Per my understanding, this is not acceptable to Azure DevOps. So, re-working some portion of `npm-packaging-pipeline.yml` to accomadate changes in #15329 ### Motivation and Context Fix NPM packaging pipeline Validating test run with fix: https://aiinfra.visualstudio.com/Lotus/_build/results?buildId=297391&view=results
Description
Motivation and Context
Reduced compilation time about one hour.
test run:
https://dev.azure.com/onnxruntime/onnxruntime/_build/results?buildId=943695&view=logs&j=de302ec2-2305-57e0-e8c6-cd89c569f2a3&t=8b360243-7783-51da-8079-2304089d3d1d