From 1bb5afe7a17a8ad39896c350dbfd35494ed40a7b Mon Sep 17 00:00:00 2001 From: Anton Iakimov Date: Mon, 6 Nov 2023 16:01:42 +0100 Subject: [PATCH] docker: add cluster-id docker_add_cluster_id_flag https://github.com/status-im/infra-waku/issues/3 https://github.com/waku-org/nwaku/pull/2062 --- defaults/main.yml | 3 +++ templates/docker-compose.yml.j2 | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/defaults/main.yml b/defaults/main.yml index 74aef4f..44f3d72 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -13,6 +13,9 @@ nim_waku_node_tmp_path: '{{ nim_waku_cont_vol }}/data/tmp' #nim_waku_node_key: ~ nim_waku_node_key_file_path: '{{ nim_waku_cont_vol }}/nodekey' +# Optional cluster-id flag +#nim_waku_cluster_id: 1 + # Protocols nim_waku_protocols_available: ['relay', 'store', 'filter', 'lightpush', 'rln-relay', 'peer-exchange'] nim_waku_protocols_enabled: ['relay', 'store', 'filter', 'lightpush'] diff --git a/templates/docker-compose.yml.j2 b/templates/docker-compose.yml.j2 index 4e5e319..14ca9c4 100644 --- a/templates/docker-compose.yml.j2 +++ b/templates/docker-compose.yml.j2 @@ -90,7 +90,10 @@ services: {% endif %} {% endif %}{# if "v1" in nim_waku_cont_tag #} {% if nim_waku_node_key is defined %} - --nodekey={{ nim_waku_node_key | mandatory }} + --nodekey={{ nim_waku_node_key }} +{% endif %} +{% if nim_waku_cluster_id is defined %} + --cluster-id={{ nim_waku_cluster_id }} {% endif %} --nat=extip:{{ nim_waku_public_address }} --log-level={{ nim_waku_log_level | upper }}