From bfc30115cde59d45b4957ff7ed649864cfa3f055 Mon Sep 17 00:00:00 2001 From: Yong Tang Date: Fri, 1 Sep 2023 20:10:56 -0700 Subject: [PATCH] Add MacOS ARM64 build agent (#1834) --- .github/workflows/build.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b717c7666..d5f1c6940 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -104,6 +104,34 @@ jobs: cat source.sh bash -x -e source.sh + macosarm64-bazel: + name: Bazel macOS arm64 + runs-on: [self-hosted, macOS, ARM64] + steps: + - uses: actions/checkout@v2 + - name: GCP + run: | + cat > service_account_creds.json << EOF + ${{ secrets.GCP_CREDS }} + EOF + - uses: actions/setup-python@v1 + with: + python-version: "3.8" + - name: Bazel on macOS + run: | + set -x -e + export BAZEL_OPTIMIZATION="--config=optimization --config=cache" + if [[ "${EVENT_NAME}" == "push" && "${REPO_NAME}" == "tensorflow/io" ]]; then + export BAZEL_OPTIMIZATION="$BAZEL_OPTIMIZATION --remote_upload_local_results=true --google_credentials=service_account_creds.json" + fi + sudo -E -H bash -e .github/workflows/build.bazel.sh python3 + - uses: actions/upload-artifact@v2 + with: + name: ${{ runner.os }}-bazel-bin + path: | + build/tensorflow_io + build/tensorflow_io_gcs_filesystem + macos-bazel: name: Bazel macOS runs-on: macOS-11