Add eth-api-proxy to mainnet-eth stack. (#514)

* Add eth-api-proxy to mainnet-eth stack.
This commit is contained in:
Thomas E Lackey 2023-08-29 16:49:09 -05:00 committed by GitHub
parent 7f9b556f9d
commit d3c26948fc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 34 additions and 1 deletions

View File

@ -0,0 +1,15 @@
version: '3.8'
services:
redis:
hostname: mainnet-eth-api-proxy-redis
image: redis:7-alpine
command: redis-server --save "" --appendonly no --maxmemory-policy allkeys-lru --maxmemory 1G
eth-api-proxy:
hostname: mainnet-eth-api-proxy
image: cerc/eth-api-proxy:local
env_file:
- ../config/mainnet-eth-api-proxy/ethpxy.env
ports:
- 8547

View File

@ -0,0 +1,6 @@
CERC_ETHPXY_LISTEN_PORT=8547
CERC_ETHPXY_LISTEN_ADDR='0.0.0.0'
CERC_ETHPXY_REDIS_URL='redis://mainnet-eth-api-proxy-redis:6379'
CERC_ETHPXY_REDIS_MAX_AGE=120000
CERC_ETHPXY_GETH_WS_URL='ws://mainnet-eth-geth-1:8546'
CERC_ETHPXY_GETH_HTTP_URL='http://mainnet-eth-geth-1:8545'

View File

@ -0,0 +1,9 @@
#!/usr/bin/env bash
# Build cerc/eth-api-proxy
source ${CERC_CONTAINER_BASE_DIR}/build-base.sh
# See: https://stackoverflow.com/a/246128/1701505
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
docker build -t cerc/eth-api-proxy:local ${build_command_args} ${CERC_REPO_BASE_DIR}/eth-api-proxy

View File

@ -23,7 +23,7 @@ def setup(ctx):
return None return None
def create(ctx): def create(ctx, extra_args):
# Generate the JWT secret and save to its config file # Generate the JWT secret and save to its config file
secret = token_hex(32) secret = token_hex(32)
jwt_file_path = ctx.deployment_dir.joinpath("data", "mainnet_eth_config_data", "jwtsecret") jwt_file_path = ctx.deployment_dir.joinpath("data", "mainnet_eth_config_data", "jwtsecret")

View File

@ -7,6 +7,7 @@ repos:
- github.com/dboreham/foundry - github.com/dboreham/foundry
- git.vdb.to/cerc-io/keycloak-reg-api - git.vdb.to/cerc-io/keycloak-reg-api
- git.vdb.to/cerc-io/keycloak-reg-ui - git.vdb.to/cerc-io/keycloak-reg-ui
- github.com/vulcanize/eth-api-proxy
containers: containers:
- cerc/go-ethereum - cerc/go-ethereum
- cerc/lighthouse - cerc/lighthouse
@ -16,8 +17,10 @@ containers:
- cerc/webapp-base - cerc/webapp-base
- cerc/keycloak-reg-api - cerc/keycloak-reg-api
- cerc/keycloak-reg-ui - cerc/keycloak-reg-ui
- cerc/eth-api-proxy
pods: pods:
- mainnet-eth - mainnet-eth
- mainnet-eth-keycloak - mainnet-eth-keycloak
- mainnet-eth-metrics - mainnet-eth-metrics
- mainnet-eth-api-proxy
- foundry - foundry