From a3d9799121141459795c390f692b0140d7466039 Mon Sep 17 00:00:00 2001 From: Gusto Date: Wed, 18 Oct 2023 16:15:03 +0300 Subject: [PATCH] Docker bootstrap node as sender receiver --- compose.yml | 2 +- testnet/bootstrap_config.yaml | 78 +++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+), 1 deletion(-) create mode 100644 testnet/bootstrap_config.yaml diff --git a/compose.yml b/compose.yml index e3a234b5..f12cd5de 100644 --- a/compose.yml +++ b/compose.yml @@ -11,7 +11,7 @@ services: - ./testnet:/etc/nomos environment: - NET_NODE_KEY=${DOCKER_COMPOSE_BOOSTRAP_NET_NODE_KEY:-1000000000000000000000000000000000000000000000000000000000000000} - command: /etc/nomos/libp2p_config.yaml + command: /etc/nomos/bootstrap_config.yaml libp2p-node: build: diff --git a/testnet/bootstrap_config.yaml b/testnet/bootstrap_config.yaml new file mode 100644 index 00000000..5168b2e4 --- /dev/null +++ b/testnet/bootstrap_config.yaml @@ -0,0 +1,78 @@ +log: + backend: "Stdout" + format: "Json" + level: "debug" +consensus: + private_key: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + fountain_settings: null + overlay_settings: + nodes: [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]] + number_of_committees: 1 + current_leader: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + leader: + cur: 0 + committee_membership: !Sad + entropy: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + leader_super_majority_threshold: 1 + super_majority_threshold: 1 + +network: + backend: + host: 0.0.0.0 + port: 3000 + log_level: "fatal" + node_key: "0000000000000000000000000000000000000000000000000000000000000001" + discV5BootstrapNodes: [] + initial_peers: [] + relayTopics: [] + # Mixclient configuration to communicate with mixnodes. + # The libp2p network backend always requires this mixclient configuration + # (cannot be disabled for now). + mixnet_client: + # A mixclient mode. For details, see the documentation of the "mixnet" crate. + # - Sender + # - !SenderReceiver [mixnode_client_listen_address] + mode: !SenderReceiver mix-node-2:7778 + # A mixnet topology, which contains the information of all mixnodes in the mixnet. + # (The topology is static for now.) + topology: + # Each mixnet layer consists of a list of mixnodes. + layers: + - nodes: + - address: mix-node-0:7777 # A listen address of the mixnode + public_key: "fd3384e132ad02a56c78f45547ee40038dc79002b90d29ed90e08eee762ae715" + - nodes: + - address: mix-node-1:7777 # A listen address of the mixnode + public_key: "fd3384e132ad02a56c78f45547ee40038dc79002b90d29ed90e08eee762ae715" + + - nodes: + - address: mix-node-2:7777 # A listen address of the mixnode + public_key: "fd3384e132ad02a56c78f45547ee40038dc79002b90d29ed90e08eee762ae715" + + + # A max number of connections that will stay connected to mixnodes in the first mixnet layer. + connection_pool_size: 255 + max_retries: 5 + retry_delay: + secs: 1 + nanos: 0 + # A range of total delay that will be set to each Sphinx packets + # sent to the mixnet for timing obfuscation. + # Panics if start > end. + mixnet_delay: + start: "0ms" + end: "0ms" + +http: + backend: + address: 0.0.0.0:8080 + cors_origins: [] + +da: + da_protocol: + num_attestations: 1 + backend: + max_capacity: 10 + evicting_period: + secs: 3600 + nanos: 0