Skip to content

Commit

Permalink
fix: mev-commit-cli.sh start minimal
Browse files Browse the repository at this point in the history
  • Loading branch information
mrekucci committed Apr 4, 2024
1 parent 0bff228 commit f5cbc16
Show file tree
Hide file tree
Showing 12 changed files with 241 additions and 105 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/mev-commit-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:

# TODO(mrekucci): Re-enable /external/geth module when tests are passing.
- name: Run Test
run: go list -f '{{.Dir}}/...' -m | grep -v '/external/geth' | xargs go test
run: go list -f '{{.Dir}}/...' -m | grep -v '/external/geth' | xargs go test -short -race

foundry:
name: Foundry Checks and Reports
Expand Down
23 changes: 13 additions & 10 deletions .github/workflows/mev-commit-infra-test.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Deploy and Test mev-commit infra
name: mev-commit-infra-test

on:
workflow_run:
Expand All @@ -8,6 +8,7 @@ on:

jobs:
deploy_and_test:
name: Deploy and Test mev-commit infra
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
Expand All @@ -26,26 +27,28 @@ jobs:

- name: Setup Docker Compose
run: |
sudo rm /usr/local/bin/docker-compose
sudo rm $(which docker-compose)
curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
- name: Build and Start Services
run: cd p2p && set -x && ./mev-commit-cli.sh start mev-commit --datadog-key "${{ secrets.DATADOG_API_KEY }}"
run: ./mev-commit-cli.sh start minimal

- name: Check Service Endpoints
run: |
ips=("172.29.9.100" "172.29.9.101" "172.29.9.102") # Example IP addresses, adjust as needed
set -x
ips=("172.29.18.2" "172.29.0.3" "172.29.0.4")
for ip in "${ips[@]}"; do
echo "Checking service at $ip"
success=false
attempts=0
success=false
while [ $attempts -lt 3 ]; do
response=$(curl -s "$ip:13523/topology")
buildersCount=$(echo "$response" | jq '.connected_peers.builders | length')
searchersCount=$(echo "$response" | jq '.connected_peers.searchers | length')
if [[ -n "$response" && "$buildersCount" -gt 0 || "$searchersCount" -gt 0 ]]; then
response=$(curl -k -s "https://$ip:13523/topology")
bidders=$(echo "$response" | jq '.connected_peers.bidders | length')
providers=$(echo "$response" | jq '.connected_peers.providers | length')
if [[ -n "$response" && "$bidders" -gt 0 || "$providers" -gt 0 ]]; then
echo "Service at $ip is OK"
success=true
break
Expand All @@ -63,4 +66,4 @@ jobs:
done
- name: Stop Services
run: cd p2p && ./mev-commit-cli.sh stop mev-commit
run: ./mev-commit-cli.sh stop minimal
5 changes: 2 additions & 3 deletions contracts-abi/clients/BidderRegistry/BidderRegistry.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions contracts-abi/clients/L1Gateway/L1Gateway.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions contracts-abi/clients/Oracle/Oracle.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions contracts-abi/clients/ProviderRegistry/ProviderRegistry.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions contracts-abi/clients/SettlementGateway/SettlementGateway.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit f5cbc16

Please sign in to comment.