chiark / gitweb /
py/tripe.py.in: Send the right command when you call `eping'.
[tripe] / svc / connect.in
index 000ca50eba511232b1ae82dd3d7af613b1b33797..e3a5022331c1f1eaa8c4f880dc238c90a31ea433 100644 (file)
 ###
 ### This file is part of Trivial IP Encryption (TrIPE).
 ###
-### TrIPE is free software; you can redistribute it and/or modify
-### it under the terms of the GNU General Public License as published by
-### the Free Software Foundation; either version 2 of the License, or
-### (at your option) any later version.
+### TrIPE is free software: you can redistribute it and/or modify it under
+### the terms of the GNU General Public License as published by the Free
+### Software Foundation; either version 3 of the License, or (at your
+### option) any later version.
 ###
-### TrIPE is distributed in the hope that it will be useful,
-### but WITHOUT ANY WARRANTY; without even the implied warranty of
-### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-### GNU General Public License for more details.
+### TrIPE is distributed in the hope that it will be useful, but WITHOUT
+### ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+### FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+### for more details.
 ###
 ### You should have received a copy of the GNU General Public License
-### along with TrIPE; if not, write to the Free Software Foundation,
-### Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+### along with TrIPE.  If not, see <https://www.gnu.org/licenses/>.
 
 VERSION = '@VERSION@'
 
@@ -127,7 +126,7 @@ class ErrorWatch (T.Coroutine):
 
 def dbwatch():
   """
-  Coroutine function: wake up every second and notice changes to the
+  Coroutine function: wake up every minute and notice changes to the
   database.  When a change happens, tell the Pinger (q.v.) to rescan its
   peers.
   """
@@ -135,7 +134,7 @@ def dbwatch():
   main = cr.parent
   fw = M.FWatch(opts.cdb)
   while True:
-    timer = M.SelTimer(time() + 1, lambda: cr.switch())
+    timer = M.SelTimer(time() + 60, lambda: cr.switch())
     main.switch()
     if fw.update():
       pinger.rescan(False)
@@ -716,7 +715,7 @@ def cmd_kick(name):
     raise T.TripeJobError('peer-not-adopted', name)
   try: peer = Peer(name)
   except KeyError: raise T.TripeJobError('unknown-peer', name)
-  T.spawn(connect, peer)
+  T.spawn(run_connect, peer, peer.get('connect'))
 
 def cmd_adopted():
   """