[build][201811] Make the build to fail if raw image generation is not successful (#15448)
This commit is contained in:
parent
d993630ab6
commit
7d46f76005
@ -60,7 +60,11 @@ elif [ "$IMAGE_TYPE" = "raw" ]; then
|
||||
## Run the installer
|
||||
## The 'build' install mode of the installer is used to generate this dump.
|
||||
sudo chmod a+x $OUTPUT_ONIE_IMAGE
|
||||
sudo ./$OUTPUT_ONIE_IMAGE
|
||||
sudo ./$OUTPUT_ONIE_IMAGE || {
|
||||
## Failure during 'build' install mode of the installer results in an incomplete raw image.
|
||||
## Delete the incomplete raw image.
|
||||
sudo rm -f $OUTPUT_RAW_IMAGE
|
||||
}
|
||||
|
||||
[ -r $OUTPUT_RAW_IMAGE ] || {
|
||||
echo "Error : $OUTPUT_RAW_IMAGE not generated!"
|
||||
|
Loading…
Reference in New Issue
Block a user