From b479399fa325f54a8e8f76dfacf8045f200faff7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Felipe=20Barco?= Date: Mon, 16 Dec 2024 12:16:42 -0500 Subject: [PATCH] Revert "Set up CI to run buck2 samples (#357)" This reverts commit d6f3530baec70f005accc0be6455466b15c62a9b. --- .github/workflows/main.yml | 26 -------------------------- buck2/cpp/.buckconfig | 2 +- buck2/cpp/README.md | 6 ++---- buck2/golang/.buckconfig | 2 +- buck2/golang/README.md | 6 ++---- buck2/python/.buckconfig | 2 +- buck2/python/README.md | 6 ++---- infra/auth-buck2.sh | 9 --------- infra/setup-buck2.sh | 12 ------------ infra/test-buck2.sh | 23 ----------------------- 10 files changed, 9 insertions(+), 85 deletions(-) delete mode 100755 infra/auth-buck2.sh delete mode 100755 infra/setup-buck2.sh delete mode 100755 infra/test-buck2.sh diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 3d324a2d..df0723d3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -102,29 +102,3 @@ jobs: OS: linux REMOTE_EXECUTION: ${{ matrix.remote_execution }} run: python3 infra/test-all.py - - buck2-test: - runs-on: - - self-hosted - - "os=linux" - - "arch=x64" - - "engflow-container-image=docker://645088952840.dkr.ecr.eu-west-1.amazonaws.com/engflow-ci/debian11-dind-x64@sha256:a0f386162b6498b9220a33f33f158fd175d2873ddd6ed30ca67aa33915850e1e" - - "engflow-pool=ci_sysbox_x64" - - "engflow-runtime=sysbox-runc" - - "engflow-runner-id=${{ github.repository_id }}_buck2-test_${{ github.run_id }}_${{ github.run_number }}_${{ github.run_attempt }}" - timeout-minutes: 10 - - steps: - - uses: actions/checkout@v4 - - - name: Set up Buck2 binary - shell: bash - run: infra/setup-buck2.sh - - - name: Set up authentication - shell: bash - run: infra/auth-buck2.sh - - - name: Build and test - shell: bash - run: infra/test-buck2.sh diff --git a/buck2/cpp/.buckconfig b/buck2/cpp/.buckconfig index 8af31dd8..c3ac155e 100644 --- a/buck2/cpp/.buckconfig +++ b/buck2/cpp/.buckconfig @@ -41,7 +41,7 @@ digest_algorithms = SHA256 engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING [build] execution_platforms = root//platforms:remote_platform diff --git a/buck2/cpp/README.md b/buck2/cpp/README.md index 1f1751f2..f75bbd7f 100644 --- a/buck2/cpp/README.md +++ b/buck2/cpp/README.md @@ -35,12 +35,10 @@ following: engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING ``` - To obtain the value of ``, log into https://.cluster.engflow.com/gettingstarted and obtain the value of `x-engflow-auth-token` in section `Method 2: JWT`, take note of this value. Then set `AUTH_HTTP_HEADERS` with the value `x-engflow-auth-method:jwt-v0,x-engflow-auth-token:. - - Note for CI runs, the auth method used is [Github Tokens](https://docs.engflow.com/re/config/authentication.html#github-tokens). + To obtain the value of `LONG_JWT_STRING`, log into https://.cluster.engflow.com/gettingstarted and use the value of `x-engflow-auth-token` in section `Method 2: JWT`. ### Usage instructions diff --git a/buck2/golang/.buckconfig b/buck2/golang/.buckconfig index 8e773e99..260c1f66 100644 --- a/buck2/golang/.buckconfig +++ b/buck2/golang/.buckconfig @@ -23,7 +23,7 @@ digest_algorithms = SHA256 engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING [build] execution_platforms = root//platforms:remote_platform diff --git a/buck2/golang/README.md b/buck2/golang/README.md index 41deea4e..603c5404 100644 --- a/buck2/golang/README.md +++ b/buck2/golang/README.md @@ -46,9 +46,7 @@ following: engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING ``` -To obtain the value of ``, log into https://.cluster.engflow.com/gettingstarted and obtain the value of `x-engflow-auth-token` in section `Method 2: JWT`, take note of this value. Then set `AUTH_HTTP_HEADERS` with the value `x-engflow-auth-method:jwt-v0,x-engflow-auth-token:. - -Note for CI runs, the auth method used is [Github Tokens](https://docs.engflow.com/re/config/authentication.html#github-tokens). +To obtain the value of `LONG_JWT_STRING`, log into https://.cluster.engflow.com/gettingstarted and use the value of `x-engflow-auth-token` in section `Method 2: JWT`. diff --git a/buck2/python/.buckconfig b/buck2/python/.buckconfig index 8e773e99..260c1f66 100644 --- a/buck2/python/.buckconfig +++ b/buck2/python/.buckconfig @@ -23,7 +23,7 @@ digest_algorithms = SHA256 engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING [build] execution_platforms = root//platforms:remote_platform diff --git a/buck2/python/README.md b/buck2/python/README.md index ff0e9af6..09dbc504 100644 --- a/buck2/python/README.md +++ b/buck2/python/README.md @@ -49,9 +49,7 @@ following: engine_address = .cluster.engflow.com action_cache_address = .cluster.engflow.com cas_address = .cluster.engflow.com -http_headers = +http_headers = x-engflow-auth-method:jwt-v0,x-engflow-auth-token:LONG_JWT_STRING ``` -To obtain the value of ``, log into https://.cluster.engflow.com/gettingstarted and obtain the value of `x-engflow-auth-token` in section `Method 2: JWT`, take note of this value. Then set `AUTH_HTTP_HEADERS` with the value `x-engflow-auth-method:jwt-v0,x-engflow-auth-token:. - -Note for CI runs, the auth method used is [Github Tokens](https://docs.engflow.com/re/config/authentication.html#github-tokens). +To obtain the value of `LONG_JWT_STRING`, log into https://.cluster.engflow.com/gettingstarted and use the value of `x-engflow-auth-token` in section `Method 2: JWT`. diff --git a/infra/auth-buck2.sh b/infra/auth-buck2.sh deleted file mode 100755 index 6cfbf1a6..00000000 --- a/infra/auth-buck2.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash -set -xe - -# Modify the buck2/**/.buckconfig files to set the test cluster to opal. -find ./ -type f -name '.buckconfig' -exec sed -i 's//opal/g' {} \; - -# Modify the buck2/**/.buckconfig files to set the "Authorization=Bearer $GITHUB_TOKEN" in the http_headers. -find ./ -type f -name '.buckconfig' -exec sed -i 's//Authorization:Bearer $GITHUB_TOKEN/g' {} \; - diff --git a/infra/setup-buck2.sh b/infra/setup-buck2.sh deleted file mode 100755 index 09faf0f2..00000000 --- a/infra/setup-buck2.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env bash -set -xe - -# Get the Buck2 binary. -curl -L -O https://github.com/facebook/buck2/releases/download/latest/buck2-x86_64-unknown-linux-musl.zst - -# Unpack the binary. -unzstd buck2-x86_64-unknown-linux-musl.zst - -# Change its name and make it executable. -mv buck2-x86_64-unknown-linux-musl buck2-exe -chmod +x buck2-exe diff --git a/infra/test-buck2.sh b/infra/test-buck2.sh deleted file mode 100755 index 710c9bba..00000000 --- a/infra/test-buck2.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash -set -xe -shopt -s expand_aliases - -alias buck2="$(realpath buck2-exe)" - -# Run cpp example -cd buck2/cpp -buck2 build //:cpp_lib -buck2 test //:cpp_test -cd .. - -# Run python example -cd python -buck2 build //main:check_main -buck2 test //hello:hello_unittest_test -cd .. - -# Run go example -cd golang -buck2 build //go:hello -buck2 test //go/greeting:greeting_test -cd ..