adding in gql and cors options

pull/6/head
Joshua Fernandes 5 years ago
parent cd2bf0bca6
commit 799f1d52f1
  1. 6
      README.md
  2. 6
      defaults/main.yml
  3. 10
      templates/config.toml.j2

@ -53,10 +53,16 @@ All variables which can be overridden are stored in [defaults/main.yml](defaults
| `besu_p2p_port` | 30303 | Specifies the P2P listening ports (UDP and TCP). Ports must be exposed appropriately |
| `besu_rpc_http_enabled` | true | Enabled the HTTP JSON-RPC service |
| `besu_rpc_http_host` | 0.0.0.0 | Specifies the host on which HTTP JSON-RPC listens |
| `besu_rpc_http_port` | 8545 | Specifies the port on which HTTP JSON-RPC listens |
| `besu_rpc_http_api` | ["ADMIN","DEBUG","NET","ETH","MINER","WEB3"] | Comma-separated APIs to enable on the HTTP JSON-RPC channel. When you use this option, the `besu_rpc_http_enabled` option must also be enabled |
| `besu_rpc_http_cors_origins` | ["all"] | Comma separated origin domain URLs for CORS validation |
| `besu_rpc_ws_enabled` | true | Enabled the WebSockets service |
| `besu_rpc_ws_host` | 0.0.0.0 | Specifies the host on which WebSockets listens |
| `besu_rpc_ws_port` | 8546 | Specifies Websockets JSON-RPC listening port (TCP). Port must be exposed appropriately |
| `besu_graphql_http_enabled` | true | Enabled the HTTP JSON-RPC service |
| `besu_graphql_http_host` | 0.0.0.0 | Specifies the host on which HTTP JSON-RPC listens |
| `besu_graphql_http_port` | 8547 | Specifies the port on which HTTP JSON-RPC listens |
| `besu_graphql_http_cors_origins` | ["all"] | Comma separated origin domain URLs for CORS validation |
| `besu_metrics_host` | 0.0.0.0 | Specifies the host on which Prometheus accesses Besu metrics. The metrics server respects the `besu_whitelist` option |
| `besu_metrics_port` | 9545 | Specifies the port on which Prometheus accesses Besu metrics |
| `besu_bootnodes` | [] | List of comma-separated enode URLs for P2P discovery bootstrap. When connecting to MainNet or public testnets, the default is a predefined list of enode URLs |

@ -35,10 +35,16 @@ besu_log_level: INFO
besu_p2p_port: 30303
besu_rpc_http_enabled: "true"
besu_rpc_http_host: 0.0.0.0
besu_rpc_http_port: 8545
besu_rpc_http_api: ["ADMIN", "DEBUG", "NET", "ETH", "MINER", "WEB3"]
besu_rpc_http_cors_origins: ["all"]
besu_rpc_ws_enabled: "true"
besu_rpc_ws_host: 0.0.0.0
besu_rpc_ws_port: 8546
besu_graphql_http_enabled: "true"
besu_graphql_http_host: 0.0.0.0
besu_graphql_http_port: 8547
besu_graphql_http_cors_origins: ["all"]
besu_metrics_host: 0.0.0.0
besu_metrics_port: 9545
besu_bootnodes: []

@ -19,7 +19,9 @@ host-whitelist=[{{besu_host_whitelist|map('to_json')|join(',')}}]
{% if besu_rpc_http_enabled|bool == True %}
rpc-http-enabled={{besu_rpc_http_enabled}}
rpc-http-host="{{besu_rpc_http_host}}"
rpc-http-port={{besu_rpc_http_port}}
rpc-http-api=[{{besu_rpc_http_api|map('to_json')|join(',')}}]
rpc-http-cors-origins=[{{besu_rpc_http_cors_origins|map('to_json')|join(',')}}]
{% endif %}
# ws
@ -29,6 +31,14 @@ rpc-ws-host="{{besu_rpc_ws_host}}"
rpc-ws-port={{besu_rpc_ws_port}}
{% endif %}
# graphql
{% if besu_rpc_graphql_enabled|bool == True %}
graphql-http-enabled={{besu_graphql_http_enabled}}
graphql-http-host="{{besu_graphql_http_host}}"
graphql-http-port={{besu_graphql_http_port}}
graphql-http-cors-origins=[{{besu_graphql_http_cors_origins|map('to_json')|join(',')}}]
{% endif %}
# p2p
{% if besu_host_ip != "" %}
p2p-host="{{besu_host_ip}}"

Loading…
Cancel
Save