diff --git a/defaults/main.yml b/defaults/main.yml index a5f76cc..dd9f75f 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -32,19 +32,20 @@ geth_rpc_addr: '127.0.0.1' geth_rpc_port: 8545 # Available: admin, clique, debug, eth, les, miner, net, personal, rpc, txpool, web3 geth_rcp_api: 'eth,net,web3,personal,admin' +# useful for linking containers +geth_rpc_extra_vhost: geth +geth_rpc_vhosts: + - 'localhost' + - '{{ geth_cont_name }}' + - '{{ geth_rpc_extra_vhost }}' + - '{{ hostname }}' + - '{{ hostname }}.tinc' + - '{{ ansible_local.tinc.vpn_ip }}' # Web Sockets API geth_websocket_enabled: true geth_websocket_port: '{{ geth_rpc_port + 1 | int }}' geth_websocket_api: 'eth,net,web3,personal,admin' geth_websocket_origins: 'localhost' -# useful for linking containers -geth_extra_alias: geth -geth_aliases: - - 'localhost' - - '{{ geth_extra_alias }}' - - '{{ hostname }}' - - '{{ hostname }}.tinc' - - '{{ ansible_local.tinc.vpn_ip }}' # Sync mode: full, fast, light geth_sync_mode: 'light' diff --git a/templates/docker-compose.yml.j2 b/templates/docker-compose.yml.j2 index a822b0e..e63e117 100644 --- a/templates/docker-compose.yml.j2 +++ b/templates/docker-compose.yml.j2 @@ -55,7 +55,7 @@ services: --http --http.addr=0.0.0.0 --http.port={{ geth_rpc_port }} - --http.vhosts={{ geth_aliases | join(",") }} + --http.vhosts={{ geth_rpc_vhosts | join(",") }} --http.api={{ geth_rcp_api }} --ipcpath=/data/geth.ipc {% endif %} @@ -70,7 +70,7 @@ services: --bootnodes="{{ geth_bootnodes | join(',') }}" {% endif %} --nousb - --verbosity={{ geth_log_level_id }} + --verbosity={{ geth_log_level_id }} --maxpeers={{ geth_max_peers }} --maxpendpeers="{{ geth_max_pend_peers }}" --port={{ geth_port }}