apiVersion: v1
kind: ConfigMap
metadata:
  name: besu-config-toml-configmap-writer-tessera
  labels:
    app: besu-config-toml-configmap-writer-tessera
  namespace: lacchain-david19
data:
  config.toml.template: |-
    # Node Information
    data-path="/data"
    genesis-file="/etc/genesis/genesis.json"

    # TODO : insert as command line & mount Volume
    # rpc-http-authentication-credentials-file="none"
    # TODO : insert as command line & mount Volume
    # rpc-ws-authentication-credentials-file="none"
    logging="INFO"

    min-gas-price=0
    # Transaction Pool
    #tx-pool-retention-hours=6
    #tx-pool-max-size=1024

    # P2P network
    p2p-enabled=true
    discovery-enabled=true
    p2p-host="${P2P_HOST}"
    p2p-port=${P2P_PORT}
    bootnodes=["enode://aef21d8ba679f55a7c28bbafb826b84cf1db929916b4d322b590037a584a0d08aef9d836289b15c2c4ce7fdb9f2f4abf705314b85fba62a8f01539e92491da80@34.73.74.151:60606","enode://4791c69f6a11486ecc6d4450aa8922865f078816176e166ccfc1882ae06272bcf71bdf7fa1d99f1a8815a7899dae0119ea06bac59a4810f92c2a9c89689610ca@35.237.20.121:60606"]


    host-allowlist=["*"]

    # JSON-RPC
    rpc-http-enabled=true
    rpc-http-host="0.0.0.0"
    rpc-http-port=4545
    rpc-http-api=["ADMIN","ETH","NET","IBFT","EEA","PRIV"]
    rpc-http-cors-origins=["*"]
    rpc-http-authentication-enabled=false

    # GRAPHQL-RPC
    graphql-http-enabled=true
    graphql-http-host="0.0.0.0"
    graphql-http-port=4547
    graphql-http-cors-origins=["*"]

    # WebSockets API
    rpc-ws-enabled=true
    rpc-ws-host="0.0.0.0"
    rpc-ws-port=4546
    rpc-ws-api=["ETH","NET","WEB3","IBFT","EEA"]
    rpc-ws-authentication-enabled=false

    # Tessera
    privacy-enabled=true
    privacy-url="http://${HOST_TESSERA}:4444"
    privacy-public-key-file="/data/tessera/keystore/nodeKey.pub"

  

