Generate RBE socket address randomly for each invocation of soong.

Test: started soong multiple times and saw different socket files in
out/soong/.temp

Change-Id: Ib0087dd3867bdbf584c6868196070840cff291aa
diff --git a/ui/build/config.go b/ui/build/config.go
index a60d70e..ba477e6 100644
--- a/ui/build/config.go
+++ b/ui/build/config.go
@@ -184,7 +184,8 @@
 	// Tell python not to spam the source tree with .pyc files.
 	ret.environ.Set("PYTHONDONTWRITEBYTECODE", "1")
 
-	ret.environ.Set("TMPDIR", absPath(ctx, ret.TempDir()))
+	tmpDir := absPath(ctx, ret.TempDir())
+	ret.environ.Set("TMPDIR", tmpDir)
 
 	// Always set ASAN_SYMBOLIZER_PATH so that ASAN-based tools can symbolize any crashes
 	symbolizerPath := filepath.Join("prebuilts/clang/host", ret.HostPrebuiltTag(),
@@ -258,6 +259,12 @@
 
 	ret.environ.Set("BUILD_DATETIME_FILE", buildDateTimeFile)
 
+	if ret.UseRBE() {
+		for k, v := range getRBEVars(ctx, tmpDir) {
+			ret.environ.Set(k, v)
+		}
+	}
+
 	return Config{ret}
 }