Adding tool to execute a remote cell-based build via Bazel.
Change-Id: I69f94c3664d8ce75e3691a9e4d8d0a2271406a4c
diff --git a/tools/dev/bin/cell-build b/tools/dev/bin/cell-build
index 524795c..8196b32 100755
--- a/tools/dev/bin/cell-build
+++ b/tools/dev/bin/cell-build
@@ -22,6 +22,10 @@
# Make sure the remote build machine is on the same commit hash as the local one
remoteCommit=\$(git log -n 1 | head -n1 | cut -d\ -f2)
+ # Clean-up the workspace and stash away any changes.
+ git clean -f
+ git stash
+
if [ "\$remoteCommit" != "$baseCommit" ]; then
git checkout master
git pull
@@ -29,10 +33,8 @@
fi
# Apply the patch
- git clean -f
- git stash
git apply --no-add /tmp/$baseCommit.patch
- # Run the build
- SHLVL=1 bazel build onos
+ # Run the build (neutralizing known environment mutations)
+ SHLVL=1 SSH_CLIENT=0 SSH_CONNECTION=0 bazel build onos
"