From d921c5ddfa9d7d346885ae48d1ce7cef88849f60 Mon Sep 17 00:00:00 2001 From: Maddiaa0 <47148561+Maddiaa0@users.noreply.github.com> Date: Thu, 2 Jan 2025 11:35:44 +0000 Subject: [PATCH 1/3] fix: change rough rhino path --- .github/workflows/ci.yml | 6 ++--- .../{rough-rhino => testnet}/Earthfile | 27 ++++++++++++++++--- .../{rough-rhino => testnet}/aztec-spartan.sh | 0 3 files changed, 27 insertions(+), 6 deletions(-) rename spartan/releases/{rough-rhino => testnet}/Earthfile (94%) rename spartan/releases/{rough-rhino => testnet}/aztec-spartan.sh (100%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9bf188fd326f..866672bda53b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -543,21 +543,21 @@ jobs: export CI=1 USE_CACHE=1 scripts/earthly-ci +prover-client-with-cache - rough-rhino-installer: + testnet-installer: needs: [bootstrap, configure] runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: { ref: "${{ github.event.pull_request.head.sha }}" } - uses: ./.github/ci-setup-action - - name: Rough Rhino Installer Helper Script + - name: Testnet Installer Helper Script uses: ./.github/ensure-builder timeout-minutes: 40 with: username: ${{ needs.configure.outputs.username }} runner_type: builder-x86 run: | - scripts/earthly-ci ./spartan/releases/rough-rhino/+test-all + scripts/earthly-ci ./spartan/releases/testnet/+test-all protocol-circuits-gates-report: needs: [ci-rest, configure] diff --git a/spartan/releases/rough-rhino/Earthfile b/spartan/releases/testnet/Earthfile similarity index 94% rename from spartan/releases/rough-rhino/Earthfile rename to spartan/releases/testnet/Earthfile index 3e0da23adfcb..9a0f52790a29 100644 --- a/spartan/releases/rough-rhino/Earthfile +++ b/spartan/releases/testnet/Earthfile @@ -23,12 +23,14 @@ test-setup: test-help: FROM +test-setup + LOCALLY RUN ./aztec-spartan.sh | grep -q "Commands:" && \ echo "✅ Help command test passed" || \ (echo "❌ Help command test failed" && exit 1) test-no-config: FROM +test-setup + LOCALLY RUN if ./aztec-spartan.sh start 2>&1 | grep -q "Configuration not found"; then \ echo "✅ No config test passed"; \ else \ @@ -38,6 +40,7 @@ test-no-config: test-install: FROM +test-setup # Test installation with CLI arguments + LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -45,6 +48,7 @@ test-install: -k 0x00 \ -n "troll-turtle" # Verify docker-compose.yml was created and contains correct values + LOCALLY RUN test -f .env && \ test -f docker-compose.yml && \ grep -q "P2P_UDP_ANNOUNCE_ADDR=1.2.3.4:40400" .env && \ @@ -56,10 +60,13 @@ test-install: test-docker-check: FROM +deps COPY aztec-spartan.sh . + LOCALLY RUN chmod +x aztec-spartan.sh # Remove docker to test docker installation check + LOCALLY RUN rm -f /usr/local/bin/docker /usr/local/bin/docker-compose # Test docker check (should fail since docker is not installed) + LOCALLY RUN if ./aztec-spartan.sh config 2>&1 | grep -q "Docker or Docker Compose not found"; then \ echo "✅ Docker check test passed"; \ else \ @@ -69,6 +76,7 @@ test-docker-check: test-start-stop: FROM +test-setup # First install with test configuration + LOCALLY RUN echo -e "\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -76,16 +84,19 @@ test-start-stop: -k 0x00 \ -n "troll-turtle" # Test start command + LOCALLY RUN ./aztec-spartan.sh start 2>&1 | grep -q "Starting containers" && \ echo "✅ Start command test passed" || \ (echo "❌ Start command test failed" && exit 1) # Test stop command + LOCALLY RUN ./aztec-spartan.sh stop 2>&1 | grep -q "Stopping containers" && \ echo "✅ Stop command test passed" || \ (echo "❌ Stop command test failed" && exit 1) test-update: FROM +test-setup + LOCALLY RUN ./aztec-spartan.sh update 2>&1 | grep -q "Pulling latest images" && \ echo "✅ Update command test passed" || \ (echo "❌ Update command test failed" && exit 1) @@ -93,6 +104,7 @@ test-update: test-data-dir: FROM +test-setup # Test installation with data directory argument + LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -101,6 +113,7 @@ test-data-dir: -d ./aztec-data \ -n "troll-turtle" # Verify docker-compose.yml uses bind mount instead of named volume + LOCALLY RUN grep -q "volumes:" docker-compose.yml && \ grep -q "./aztec-data:/var/lib/aztec" docker-compose.yml && \ ! grep -q "volumes:\n aztec_data:" docker-compose.yml && \ @@ -110,6 +123,7 @@ test-data-dir: test-p2p-key: FROM +test-setup # Test installation with P2P private key argument + LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -118,13 +132,16 @@ test-p2p-key: -pk 00000 \ -n "troll-turtle" # Verify the P2P private key was set in the .env file + LOCALLY RUN test -f .env && \ grep -q "PEER_ID_PRIVATE_KEY=00000" .env && \ echo "✅ P2P private key test passed" || \ (echo "❌ P2P private key test failed" && exit 1) test-ethereum-host: + LOCALLY FROM +test-setup + LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -n "troll-turtle" \ -e http://foobar:8545 \ @@ -133,12 +150,14 @@ test-ethereum-host: -ip 1.2.3.4 \ -k 0x00 \ -pk 00000 + LOCALLY RUN test -f .env && \ grep -q "ETHEREUM_HOST=http://foobar:8545" .env && \ echo "✅ Ethereum host cli test passed" || \ (echo "❌ Ethereum host cli test failed" && exit 1) # We don't respect the env var here + LOCALLY RUN echo -e "\n\n" | ETHEREUM_HOST=http://foobar:8545 ./aztec-spartan.sh config \ -n "troll-turtle" \ -p 8080 \ @@ -146,6 +165,7 @@ test-ethereum-host: -ip 1.2.3.4 \ -k 0x00 \ -pk 00000 + LOCALLY RUN test -f .env && \ grep -q "ETHEREUM_HOST=http://34.19.127.9:8545" .env && \ echo "✅ Ethereum host override test passed" || \ @@ -153,9 +173,10 @@ test-ethereum-host: test-all: - BUILD +test-help - BUILD +test-install - BUILD +test-docker-check + # BUILD +test-help + # BUILD +test-install + + # BUILD +test-docker-check BUILD +test-start-stop BUILD +test-update BUILD +test-data-dir diff --git a/spartan/releases/rough-rhino/aztec-spartan.sh b/spartan/releases/testnet/aztec-spartan.sh similarity index 100% rename from spartan/releases/rough-rhino/aztec-spartan.sh rename to spartan/releases/testnet/aztec-spartan.sh From ef577ee44c88662f70834bd3c8fb4461f262d2f6 Mon Sep 17 00:00:00 2001 From: Maddiaa0 <47148561+Maddiaa0@users.noreply.github.com> Date: Thu, 2 Jan 2025 11:45:26 +0000 Subject: [PATCH 2/3] chore: disable tt test --- .github/workflows/ci.yml | 30 +++++++++++------------ spartan/releases/testnet/Earthfile | 29 +++------------------- spartan/releases/testnet/aztec-spartan.sh | 8 +++--- 3 files changed, 23 insertions(+), 44 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 866672bda53b..3c2bef0f1f39 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -543,21 +543,21 @@ jobs: export CI=1 USE_CACHE=1 scripts/earthly-ci +prover-client-with-cache - testnet-installer: - needs: [bootstrap, configure] - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: { ref: "${{ github.event.pull_request.head.sha }}" } - - uses: ./.github/ci-setup-action - - name: Testnet Installer Helper Script - uses: ./.github/ensure-builder - timeout-minutes: 40 - with: - username: ${{ needs.configure.outputs.username }} - runner_type: builder-x86 - run: | - scripts/earthly-ci ./spartan/releases/testnet/+test-all + # testnet-installer: + # needs: [bootstrap, configure] + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # with: { ref: "${{ github.event.pull_request.head.sha }}" } + # - uses: ./.github/ci-setup-action + # - name: Testnet Installer Helper Script + # uses: ./.github/ensure-builder + # timeout-minutes: 40 + # with: + # username: ${{ needs.configure.outputs.username }} + # runner_type: builder-x86 + # run: | + # scripts/earthly-ci ./spartan/releases/testnet/+test-all protocol-circuits-gates-report: needs: [ci-rest, configure] diff --git a/spartan/releases/testnet/Earthfile b/spartan/releases/testnet/Earthfile index 9a0f52790a29..45a3c82c32f4 100644 --- a/spartan/releases/testnet/Earthfile +++ b/spartan/releases/testnet/Earthfile @@ -23,14 +23,12 @@ test-setup: test-help: FROM +test-setup - LOCALLY RUN ./aztec-spartan.sh | grep -q "Commands:" && \ echo "✅ Help command test passed" || \ (echo "❌ Help command test failed" && exit 1) test-no-config: FROM +test-setup - LOCALLY RUN if ./aztec-spartan.sh start 2>&1 | grep -q "Configuration not found"; then \ echo "✅ No config test passed"; \ else \ @@ -40,7 +38,6 @@ test-no-config: test-install: FROM +test-setup # Test installation with CLI arguments - LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -48,7 +45,6 @@ test-install: -k 0x00 \ -n "troll-turtle" # Verify docker-compose.yml was created and contains correct values - LOCALLY RUN test -f .env && \ test -f docker-compose.yml && \ grep -q "P2P_UDP_ANNOUNCE_ADDR=1.2.3.4:40400" .env && \ @@ -60,13 +56,10 @@ test-install: test-docker-check: FROM +deps COPY aztec-spartan.sh . - LOCALLY RUN chmod +x aztec-spartan.sh # Remove docker to test docker installation check - LOCALLY RUN rm -f /usr/local/bin/docker /usr/local/bin/docker-compose # Test docker check (should fail since docker is not installed) - LOCALLY RUN if ./aztec-spartan.sh config 2>&1 | grep -q "Docker or Docker Compose not found"; then \ echo "✅ Docker check test passed"; \ else \ @@ -76,7 +69,6 @@ test-docker-check: test-start-stop: FROM +test-setup # First install with test configuration - LOCALLY RUN echo -e "\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -84,19 +76,16 @@ test-start-stop: -k 0x00 \ -n "troll-turtle" # Test start command - LOCALLY RUN ./aztec-spartan.sh start 2>&1 | grep -q "Starting containers" && \ echo "✅ Start command test passed" || \ (echo "❌ Start command test failed" && exit 1) # Test stop command - LOCALLY RUN ./aztec-spartan.sh stop 2>&1 | grep -q "Stopping containers" && \ echo "✅ Stop command test passed" || \ (echo "❌ Stop command test failed" && exit 1) test-update: FROM +test-setup - LOCALLY RUN ./aztec-spartan.sh update 2>&1 | grep -q "Pulling latest images" && \ echo "✅ Update command test passed" || \ (echo "❌ Update command test failed" && exit 1) @@ -104,7 +93,6 @@ test-update: test-data-dir: FROM +test-setup # Test installation with data directory argument - LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -113,7 +101,6 @@ test-data-dir: -d ./aztec-data \ -n "troll-turtle" # Verify docker-compose.yml uses bind mount instead of named volume - LOCALLY RUN grep -q "volumes:" docker-compose.yml && \ grep -q "./aztec-data:/var/lib/aztec" docker-compose.yml && \ ! grep -q "volumes:\n aztec_data:" docker-compose.yml && \ @@ -123,7 +110,6 @@ test-data-dir: test-p2p-key: FROM +test-setup # Test installation with P2P private key argument - LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -p 8080 \ -p2p 40400 \ @@ -132,16 +118,13 @@ test-p2p-key: -pk 00000 \ -n "troll-turtle" # Verify the P2P private key was set in the .env file - LOCALLY RUN test -f .env && \ grep -q "PEER_ID_PRIVATE_KEY=00000" .env && \ echo "✅ P2P private key test passed" || \ (echo "❌ P2P private key test failed" && exit 1) test-ethereum-host: - LOCALLY FROM +test-setup - LOCALLY RUN echo -e "\n\n" | ./aztec-spartan.sh config \ -n "troll-turtle" \ -e http://foobar:8545 \ @@ -150,14 +133,12 @@ test-ethereum-host: -ip 1.2.3.4 \ -k 0x00 \ -pk 00000 - LOCALLY RUN test -f .env && \ grep -q "ETHEREUM_HOST=http://foobar:8545" .env && \ echo "✅ Ethereum host cli test passed" || \ (echo "❌ Ethereum host cli test failed" && exit 1) # We don't respect the env var here - LOCALLY RUN echo -e "\n\n" | ETHEREUM_HOST=http://foobar:8545 ./aztec-spartan.sh config \ -n "troll-turtle" \ -p 8080 \ @@ -165,7 +146,6 @@ test-ethereum-host: -ip 1.2.3.4 \ -k 0x00 \ -pk 00000 - LOCALLY RUN test -f .env && \ grep -q "ETHEREUM_HOST=http://34.19.127.9:8545" .env && \ echo "✅ Ethereum host override test passed" || \ @@ -173,12 +153,11 @@ test-ethereum-host: test-all: - # BUILD +test-help - # BUILD +test-install - - # BUILD +test-docker-check + BUILD +test-help + BUILD +test-install + BUILD +test-docker-check BUILD +test-start-stop BUILD +test-update BUILD +test-data-dir BUILD +test-p2p-key - BUILD +test-ethereum-host + BUILD +test-ethereum-host \ No newline at end of file diff --git a/spartan/releases/testnet/aztec-spartan.sh b/spartan/releases/testnet/aztec-spartan.sh index 283aeaed7cd7..2b90bf5fc0ea 100755 --- a/spartan/releases/testnet/aztec-spartan.sh +++ b/spartan/releases/testnet/aztec-spartan.sh @@ -78,10 +78,10 @@ parse_args() { show_banner() { echo -e "${BLUE}" echo " _ ____ _____ _____ _____ _____ _____ ____ _____ _ _ _____ _____ " - echo " / \ |_ /|_ _| ____| __/ |_ _| ____/ ___|_ _| \ | | ____|_ _|" - echo " / _ \ / / | | | _| | | | | | _| \___ \ | | | \| | _| | | " - echo " / ___ \/ /_ | | | |___ | |__ | | | |___ ___) || | | |\ | |___ | | " - echo "/_/ \_\___| |_| |______|____\ |_| |_____|____/ |_| |_| \_|_____| |_| " + echo " / \ |_ /|_ _| _____| __/|_ _| ____/ ___|_ _| \ | | ____|_ _|" + echo " / _ \ / / | | | _| | | | | | _| \___ \ | | | \| | _| | | " + echo " / ___ \/ /_ | | | |___ | |__ | | | |___ ___) || | | |\ | |___ | | " + echo "/_/ \_\___| |_| |______|____\ |_| |_____|____/ |_| |_| \_|_____| |_| " echo -e "${NC}" } From 8688db19335cc649479f60d9274d3da10e2c75b1 Mon Sep 17 00:00:00 2001 From: Maddiaa0 <47148561+Maddiaa0@users.noreply.github.com> Date: Thu, 2 Jan 2025 11:49:33 +0000 Subject: [PATCH 3/3] fix: remove publish npm --- .github/workflows/ci.yml | 2 +- .github/workflows/publish-aztec-packages.yml | 10 ---------- spartan/releases/create-spartan.sh | 2 +- 3 files changed, 2 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3c2bef0f1f39..a2b9707eb73a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -656,7 +656,7 @@ jobs: - kind-network-smoke - kind-network-test - boxes-test - - rough-rhino-installer + # - testnet-installer if: always() outputs: failure: ${{ steps.set_failed_jobs.outputs.failure }} diff --git a/.github/workflows/publish-aztec-packages.yml b/.github/workflows/publish-aztec-packages.yml index fa3f8a053e30..0f1549677aad 100644 --- a/.github/workflows/publish-aztec-packages.yml +++ b/.github/workflows/publish-aztec-packages.yml @@ -316,16 +316,6 @@ jobs: --VERSION=${{ steps.version_step.outputs.VERSION }} \ --DRY_RUN=${{ (github.event.inputs.publish == 'false') && '1' || '0' }} - - name: Publish spartan NPM package - run: | - earthly-ci \ - --no-output \ - --secret NPM_TOKEN=${{ env.NPM_TOKEN }} \ - ./spartan/releases/rough-rhino+publish-npm \ - --DIST_TAG=${{ steps.version_step.outputs.DIST_TAG }} \ - --VERSION=${{ steps.version_step.outputs.VERSION }} \ - --DRY_RUN=${{ (github.event.inputs.publish == 'false') && '1' || '0' }} - publish-aztec-up: needs: [configure, publish-manifests] runs-on: ubuntu-latest diff --git a/spartan/releases/create-spartan.sh b/spartan/releases/create-spartan.sh index 7fd1dd89d3be..6c688eec227b 100755 --- a/spartan/releases/create-spartan.sh +++ b/spartan/releases/create-spartan.sh @@ -1,7 +1,7 @@ #!/bin/bash # URL of the aztec-spartan.sh script -DEFAULT_URL="https://raw.githubusercontent.com/AztecProtocol/aztec-packages/refs/heads/master/spartan/releases/rough-rhino/aztec-spartan.sh" +DEFAULT_URL="https://raw.githubusercontent.com/AztecProtocol/aztec-packages/refs/heads/master/spartan/releases/testnet/aztec-spartan.sh" # Colors for output GREEN='\033[0;32m'