Skip to content

Commit

Permalink
feat: implement signer registration repeater delay in infra
Browse files Browse the repository at this point in the history
  • Loading branch information
jpraynaud committed Apr 17, 2024
1 parent 8a27962 commit 94aefc2
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 0 deletions.
Expand Up @@ -89,6 +89,7 @@ services:
- SERVER_PORT=${SIGNER_RELAY_SERVER_PORT}
- AGGREGATOR_ENDPOINT=http://${AGGREGATOR_CREDENTIALS}mithril-aggregator:8080/aggregator
- DIAL_TO=/dns4/mithril-aggregator-relay/tcp/${AGGREGATOR_RELAY_LISTEN_PORT}
- SIGNER_REPEATER_DELAY=${SIGNER_RELAY_REGISTRATION_REPEATER_DELAY}
ports:
- "${SIGNER_RELAY_LISTEN_PORT}:${SIGNER_RELAY_LISTEN_PORT}"
- "${SIGNER_RELAY_SERVER_PORT}:${SIGNER_RELAY_SERVER_PORT}"
Expand Down
Expand Up @@ -147,6 +147,7 @@ services:
- SERVER_PORT=${SIGNER_RELAY_SERVER_PORT}
- AGGREGATOR_ENDPOINT=http://${AGGREGATOR_CREDENTIALS}mithril-aggregator:8080/aggregator
- DIAL_TO=/dns4/mithril-aggregator-relay/tcp/${AGGREGATOR_RELAY_LISTEN_PORT}
- SIGNER_REPEATER_DELAY=${SIGNER_RELAY_REGISTRATION_REPEATER_DELAY}
ports:
- "${SIGNER_RELAY_LISTEN_PORT}:${SIGNER_RELAY_LISTEN_PORT}"
- "${SIGNER_RELAY_SERVER_PORT}:${SIGNER_RELAY_SERVER_PORT}"
Expand Down
1 change: 1 addition & 0 deletions mithril-infra/mithril.signer.tf
Expand Up @@ -85,6 +85,7 @@ EOT
"export AGGREGATOR_RELAY_LISTEN_PORT='${local.mithril_aggregator_relay_mithril_listen_port}'",
"export SIGNER_RELAY_LISTEN_PORT='${local.mithril_signers_relay_listen_port[each.key]}'",
"export SIGNER_RELAY_SERVER_PORT='${local.mithril_signers_relay_server_port[each.key]}'",
"export SIGNER_RELAY_REGISTRATION_REPEATER_DELAY='${var.mithril_p2p_signer_registration_repeat_delay}'",
"export ENABLE_METRICS_SERVER=true",
"export METRICS_SERVER_IP=0.0.0.0",
"export METRICS_SERVER_PORT=9090",
Expand Down
6 changes: 6 additions & 0 deletions mithril-infra/variables.tf
Expand Up @@ -178,6 +178,12 @@ variable "mithril_use_p2p_network" {
default = false
}

variable "mithril_p2p_signer_registration_repeat_delay" {
type = number
description = "The repeat delay in milliseconds for the signer registration when operating in P2P mode (defaults to 1 hour)"
default = 3600 * 1000
}

locals {
mithril_network_type_suffix = var.mithril_use_p2p_network ? "-p2p" : ""
}
Expand Down

0 comments on commit 94aefc2

Please sign in to comment.