From 21655bc539ad786ee8a76e01a66eaa85c4992c5c Mon Sep 17 00:00:00 2001 From: Weimin Yu Date: Fri, 19 Mar 2021 11:28:18 -0400 Subject: [PATCH] Allow nom_build to run in Cloudbuild (#1021) * Allow nom_build to run in Cloudbuild Our builder comes with python3.6 and cannot support nom_build out of box. Nom_build requires dataclasses which is introduced in v3.7. I haven't found an easy way to get python3.7+ without changing the base linux image. This PR explicitly installs dataclasses. --- release/builder/build.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/release/builder/build.sh b/release/builder/build.sh index 87c87c3d3..97304a53e 100755 --- a/release/builder/build.sh +++ b/release/builder/build.sh @@ -23,6 +23,10 @@ apt-get upgrade -y apt-get install openjdk-11-jdk-headless -y # Install Python apt-get install python -y +# As of March 2021 python3 is at v3.6. Get pip then install dataclasses +# (introduced in 3.7) for nom_build +apt-get install python3-pip -y +python3 -m pip install dataclasses # Install Node curl -sL https://deb.nodesource.com/setup_current.x | bash - apt-get install -y nodejs