2017-01-30 22:10:16 +04:00
|
|
|
(**************************************************************************)
|
|
|
|
(* *)
|
2018-02-06 00:17:03 +04:00
|
|
|
(* Copyright (c) 2014 - 2018. *)
|
2017-01-30 22:10:16 +04:00
|
|
|
(* Dynamic Ledger Solutions, Inc. <contact@tezos.com> *)
|
|
|
|
(* *)
|
|
|
|
(* All rights reserved. No warranty, explicit or implicit, provided. *)
|
|
|
|
(* *)
|
|
|
|
(**************************************************************************)
|
|
|
|
|
|
|
|
type t = {
|
|
|
|
data_dir : string ;
|
2018-02-16 04:26:24 +04:00
|
|
|
p2p : p2p ;
|
2017-01-30 22:10:16 +04:00
|
|
|
rpc : rpc ;
|
|
|
|
log : log ;
|
2017-11-11 06:34:12 +04:00
|
|
|
shell : shell ;
|
2017-01-30 22:10:16 +04:00
|
|
|
}
|
|
|
|
|
2018-02-16 04:26:24 +04:00
|
|
|
and p2p = {
|
2017-01-30 22:10:16 +04:00
|
|
|
expected_pow : float ;
|
|
|
|
bootstrap_peers : string list ;
|
|
|
|
listen_addr : string option ;
|
2018-05-17 13:33:33 +04:00
|
|
|
private_mode : bool ;
|
2017-01-30 22:10:16 +04:00
|
|
|
limits : P2p.limits ;
|
2018-05-09 21:19:56 +04:00
|
|
|
disable_mempool : bool ;
|
2017-01-30 22:10:16 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
and rpc = {
|
|
|
|
listen_addr : string option ;
|
|
|
|
cors_origins : string list ;
|
|
|
|
cors_headers : string list ;
|
|
|
|
tls : tls option ;
|
|
|
|
}
|
|
|
|
|
|
|
|
and tls = {
|
|
|
|
cert : string ;
|
|
|
|
key : string ;
|
|
|
|
}
|
|
|
|
|
|
|
|
and log = {
|
2018-02-08 13:51:01 +04:00
|
|
|
output : Logging_unix.Output.t ;
|
2017-01-30 22:10:16 +04:00
|
|
|
default_level : Logging.level ;
|
|
|
|
rules : string option ;
|
|
|
|
template : Logging.template ;
|
|
|
|
}
|
|
|
|
|
2017-11-11 06:34:12 +04:00
|
|
|
and shell = {
|
2018-01-26 16:10:20 +04:00
|
|
|
block_validator_limits : Node.block_validator_limits ;
|
2017-11-29 16:51:06 +04:00
|
|
|
prevalidator_limits : Node.prevalidator_limits ;
|
2018-01-22 20:47:18 +04:00
|
|
|
peer_validator_limits : Node.peer_validator_limits ;
|
2018-02-16 04:26:24 +04:00
|
|
|
chain_validator_limits : Node.chain_validator_limits ;
|
2017-11-11 06:34:12 +04:00
|
|
|
}
|
|
|
|
|
2017-01-30 22:10:16 +04:00
|
|
|
val default_data_dir: string
|
2018-02-16 04:26:24 +04:00
|
|
|
val default_p2p_port: int
|
2017-01-30 22:10:16 +04:00
|
|
|
val default_rpc_port: int
|
2018-02-16 04:26:24 +04:00
|
|
|
val default_p2p: p2p
|
2017-01-30 22:10:16 +04:00
|
|
|
val default_config: t
|
|
|
|
|
|
|
|
val update:
|
|
|
|
?data_dir:string ->
|
|
|
|
?min_connections:int ->
|
|
|
|
?expected_connections:int ->
|
|
|
|
?max_connections:int ->
|
|
|
|
?max_download_speed:int ->
|
|
|
|
?max_upload_speed:int ->
|
2017-04-18 20:32:31 +04:00
|
|
|
?binary_chunks_size:int->
|
2017-01-24 17:36:42 +04:00
|
|
|
?peer_table_size:int ->
|
2017-01-30 22:10:16 +04:00
|
|
|
?expected_pow:float ->
|
|
|
|
?bootstrap_peers:string list ->
|
|
|
|
?listen_addr:string ->
|
|
|
|
?rpc_listen_addr:string ->
|
2018-05-17 13:33:33 +04:00
|
|
|
?private_mode:bool ->
|
2018-05-09 21:19:56 +04:00
|
|
|
?disable_mempool:bool ->
|
2017-01-30 22:10:16 +04:00
|
|
|
?cors_origins:string list ->
|
|
|
|
?cors_headers:string list ->
|
|
|
|
?rpc_tls:tls ->
|
2018-02-08 13:51:01 +04:00
|
|
|
?log_output:Logging_unix.Output.t ->
|
2017-11-11 06:34:12 +04:00
|
|
|
?bootstrap_threshold:int ->
|
2017-09-14 12:26:05 +04:00
|
|
|
t -> t tzresult Lwt.t
|
2017-01-30 22:10:16 +04:00
|
|
|
|
|
|
|
val to_string: t -> string
|
|
|
|
val read: string -> t tzresult Lwt.t
|
|
|
|
val write: string -> t -> unit tzresult Lwt.t
|
|
|
|
|
2018-01-24 15:48:25 +04:00
|
|
|
val resolve_listening_addrs: string -> (P2p_addr.t * int) list Lwt.t
|
|
|
|
val resolve_rpc_listening_addrs: string -> (P2p_addr.t * int) list Lwt.t
|
|
|
|
val resolve_bootstrap_addrs: string list -> (P2p_addr.t * int) list Lwt.t
|
2017-01-30 22:10:16 +04:00
|
|
|
|
2018-02-19 21:49:30 +04:00
|
|
|
val encoding: t Data_encoding.t
|
|
|
|
|
2017-01-30 22:10:16 +04:00
|
|
|
val check: t -> unit Lwt.t
|