[ci] Add OVERRIDE_BUILD_OPTIONS in image build template. (#15309)
Why I did it Set build options in pipeline UI. Support setting reproducible build options to py2,py3 in release branch and none in master branch. Work item tracking Microsoft ADO (number only): 22335854 How I did it How to verify it
This commit is contained in:
parent
15021cf12a
commit
b660bac73b
@ -28,11 +28,13 @@ jobs:
|
||||
- template: .azure-pipelines/cleanup.yml@buildimage
|
||||
- ${{ parameters.preSteps }}
|
||||
- script: |
|
||||
BUILD_OPTIONS="$(BUILD_OPTIONS)"
|
||||
[ -n "$OVERRIDE_BUILD_OPTIONS" ] && OVERRIDE_BUILD_OPTIONS=$(OVERRIDE_BUILD_OPTIONS)
|
||||
BUILD_OPTIONS="$(BUILD_OPTIONS) $OVERRIDE_BUILD_OPTIONS"
|
||||
if [ -n "$(CACHE_MODE)" ] && echo $(PLATFORM_AZP) | grep -E -q "^(vs|broadcom|mellanox|marvell-armhf)$"; then
|
||||
CACHE_OPTIONS="SONIC_DPKG_CACHE_METHOD=$(CACHE_MODE) SONIC_DPKG_CACHE_SOURCE=/nfs/dpkg_cache/$(PLATFORM_AZP)"
|
||||
BUILD_OPTIONS="$(BUILD_OPTIONS) $CACHE_OPTIONS"
|
||||
BUILD_OPTIONS="$BUILD_OPTIONS $CACHE_OPTIONS"
|
||||
fi
|
||||
echo $BUILD_OPTIONS
|
||||
echo "##vso[task.setvariable variable=BUILD_OPTIONS]$BUILD_OPTIONS"
|
||||
displayName: "Set cache options"
|
||||
- checkout: self
|
||||
|
Loading…
Reference in New Issue
Block a user