Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ethereum-package
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vicotor
ethereum-package
Commits
293001a1
Unverified
Commit
293001a1
authored
Jun 20, 2024
by
pk910
Committed by
GitHub
Jun 20, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: add mev relays to dora config (#679)
parent
cb203ff1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
5 deletions
+39
-5
main.star
main.star
+7
-0
dora_launcher.star
src/dora/dora_launcher.star
+22
-5
config.yaml.tmpl
static_files/dora-config/config.yaml.tmpl
+10
-0
No files found.
main.star
View file @
293001a1
...
...
@@ -191,6 +191,7 @@ def run(plan, args={}):
)
mev_endpoints = []
mev_endpoint_names = []
# passed external relays get priority
# perhaps add mev_type External or remove this
if (
...
...
@@ -198,6 +199,8 @@ def run(plan, args={}):
and participant.builder_network_params != None
):
mev_endpoints = participant.builder_network_params.relay_end_points
for idx, mev_endpoint in enumerate(mev_endpoints):
mev_endpoint_names.append("relay-{0}".format(idx + 1))
# otherwise dummy relays spinup if chosen
elif (
args_with_right_defaults.mev_type
...
...
@@ -219,6 +222,7 @@ def run(plan, args={}):
global_node_selectors,
)
mev_endpoints.append(endpoint)
mev_endpoint_names.append(constants.MOCK_MEV_TYPE)
elif args_with_right_defaults.mev_type and (
args_with_right_defaults.mev_type == constants.FLASHBOTS_MEV_TYPE
or args_with_right_defaults.mev_type == constants.MEV_RS_MEV_TYPE
...
...
@@ -288,6 +292,7 @@ def run(plan, args={}):
normal_user.private_key,
)
mev_endpoints.append(endpoint)
mev_endpoint_names.append(args_with_right_defaults.mev_type)
# spin up the mev boost contexts if some endpoints for relays have been passed
all_mevboost_contexts = []
...
...
@@ -451,6 +456,8 @@ def run(plan, args={}):
network_params,
dora_params,
global_node_selectors,
mev_endpoints,
mev_endpoint_names,
)
plan.print("Successfully launched dora")
elif additional_service == "dugtrio":
...
...
src/dora/dora_launcher.star
View file @
293001a1
...
...
@@ -36,6 +36,8 @@ def launch_dora(
network_params,
dora_params,
global_node_selectors,
mev_endpoints,
mev_endpoint_names,
):
all_cl_client_info = []
all_el_client_info = []
...
...
@@ -59,8 +61,22 @@ def launch_dora(
)
)
mev_endpoint_info = []
for index, endpoint in enumerate(mev_endpoints):
mev_endpoint_info.append(
{
"Index": index,
"Name": mev_endpoint_names[index],
"Url": endpoint,
}
)
template_data = new_config_template_data(
network_params.network, HTTP_PORT_NUMBER, all_cl_client_info, all_el_client_info
network_params.network,
HTTP_PORT_NUMBER,
all_cl_client_info,
all_el_client_info,
mev_endpoint_info,
)
template_and_data = shared_utils.new_template_and_data(
...
...
@@ -103,9 +119,7 @@ def get_config(
elif network_params.electra_fork_epoch < 100000000:
IMAGE_NAME = "ethpandaops/dora:electra-support"
else:
IMAGE_NAME = (
"ethpandaops/dora:master" # TODO: revert to latest after next dora release
)
IMAGE_NAME = "ethpandaops/dora:latest"
return ServiceConfig(
image=IMAGE_NAME,
...
...
@@ -125,12 +139,15 @@ def get_config(
)
def new_config_template_data(network, listen_port_num, cl_client_info, el_client_info):
def new_config_template_data(
network, listen_port_num, cl_client_info, el_client_info, mev_endpoint_info
):
return {
"Network": network,
"ListenPortNum": listen_port_num,
"CLClientInfo": cl_client_info,
"ELClientInfo": el_client_info,
"MEVRelayInfo": mev_endpoint_info,
"PublicNetwork": True if network in constants.PUBLIC_NETWORKS else False,
}
...
...
static_files/dora-config/config.yaml.tmpl
View file @
293001a1
...
...
@@ -68,6 +68,16 @@ indexer:
# number of seconds to wait between each epoch (don't overload CL client)
syncEpochCooldown: 1
mevIndexer:
# list of mev relays to crawl mev blocks from
relays: {{ if not .MEVRelayInfo }}[]{{ end }}
{{ range $relay := .MEVRelayInfo }}
- index: {{ $relay.Index }}
name: "{{ $relay.Name }}"
url: "{{ $relay.Url }}"
{{- end }}
refreshInterval: 5m
database:
engine: "sqlite"
sqlite:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment