]> Cypherpunks.ru repositories - nncp.git/blobdiff - doc/cfg.texi
NNCP_SENDER envvar while sendmail calling
[nncp.git] / doc / cfg.texi
index 19cfe40f9fd697dbfe0f8a2a88ee6606b6475946..0420d3959fec7352b25e7695cd1159fec9d3f12a 100644 (file)
@@ -35,15 +35,22 @@ neigh:
     noisepub: UBM5K...VI42A
     sendmail: ["/bin/sh", "-c", "false"]
     incoming: /home/alice/incoming
+    onlinedeadline: 1800
+    maxonlinetime: 3600
     addrs:
       lan: "[fe80::1234%igb0]:5400"
       internet: alice.com:3389
+    calls:
+      -
+        cron: "*/2 * * * *"
   bob:
     id: 2IZNP...UYGYA
     exchpub: WFLMZ...B7NHA
     signpub: GTGXG...IE3OA
     sendmail: [/usr/sbin/sendmail]
     freq: /home/bob/pub
+    freqchunked: 1024
+    freqminsize: 2048
     via: [alice]
 @end verbatim
 
@@ -51,12 +58,13 @@ neigh:
 directory. @strong{log} field contains an absolute path to @ref{Log,
 log} file.
 
+@anchor{CfgNotify}
 @strong{notify} section contains notification settings for successfully
 tossed file and freq packets. Corresponding @strong{from} and
-@strong{to} fields will substituted in notification email message.
-@emph{neigh/self/sendmail} will be used as a local mailer. If either of
-@emph{from}/@emph{to} fields are omitted, then no notification will be
-sent.
+@strong{to} fields will be substituted in notification email message.
+@emph{neigh/self/sendmail} will be used as a local mailer. You can omit
+either of those two @emph{from}/@emph{to} sections to omit corresponding
+notifications, or the whole section at once.
 
 @strong{self} section contains our node's private keypairs.
 @strong{exch*} and @strong{sign*} are used during @ref{Encrypted,
@@ -72,32 +80,69 @@ Except for @emph{id}, @emph{exchpub} and @emph{signpub} each neighbour
 node has the following fields:
 
 @table @strong
+
 @item noisepub
 If present, then node can be online called using @ref{Sync,
 synchronization protocol}. Contains authentication public key.
 
+@anchor{CfgSendmail}
 @item sendmail
 An array containing path to executable and its command line arguments
-that is called for mail sending.
+that is called for mail sending. If it is empty, then no mail processing
+will be performed from that node. Sendmail command
+@command{["/bin/foo", "bar"]} called the following way:
+@command{NNCP_SENDER=NODEID /bin/foo bar RCPT1 RCPT2 ... < MSG}.
 
+@anchor{CfgIncoming}
 @item incoming
 Full path to directory where all file uploads will be saved. May be
 omitted to forbid file uploading on that node.
 
+@anchor{CfgFreq}
 @item freq
 Full path to directory from where file requests will queue files for
 transmission. May be omitted to forbid freqing from that node.
 
+@item freqchunked
+If set, then enable @ref{Chunked, chunked} file transmission during
+freqing. This is the desired chunk size in KiBs.
+
+@item freqminsize
+If set, then apply @ref{OptMinSize, -minsize} option during file
+transmission.
+
 @item via
 An array of node identifiers that will be used as a relay to that node.
 For example @verb{|[foo,bar]|} means that packet can reach current node
 by transitioning through @emph{foo} and then @emph{bar} nodes. May be
 omitted if direct connection exists and no relaying is required.
 
+@anchor{CfgAddrs}
 @item addrs
 Dictionary containing known network addresses of the node. Each key is
 human-readable name of the link/address. Values are @verb{|addr:port|}
 pairs pointing to @ref{nncp-daemon}'s listening instance. May be omitted
 if either no direct connection exists, or @ref{nncp-call} is used with
 forced address specifying.
+
+@anchor{CfgOnlineDeadline}
+@item onlinedeadline
+Online connection deadline of node inactivity in seconds. It is the time
+connection considered dead after not receiving/sending any packets and
+node must disconnect. By default it is set to 10 seconds -- that means
+disconnecting after 10 seconds when no packets received and transmitted.
+This can be set to rather high values to keep connection alive (to
+reduce handshake overhead and delays), wait for appearing packets ready
+to send and notifying remote side about their appearance.
+
+@anchor{CfgMaxOnlineTime}
+@item maxonlinetime
+If greater than zero, then it is maximal amount of time connect could be
+alive. Forcefully disconnect if it is exceeded.
+
+@anchor{CfgCalls}
+@item calls
+List of @ref{Call, call configuration}s. Can be omitted if
+@ref{nncp-caller} won't be used to call that node.
+
 @end table