Switch to tor
This commit is contained in:
parent
32fb2edb71
commit
f844bf10d3
1 changed files with 2 additions and 10 deletions
|
@ -5,24 +5,16 @@
|
||||||
#:use-module (goblins actor-lib sealers)
|
#:use-module (goblins actor-lib sealers)
|
||||||
#:use-module (goblins ocapn captp)
|
#:use-module (goblins ocapn captp)
|
||||||
#:use-module (goblins ocapn ids)
|
#:use-module (goblins ocapn ids)
|
||||||
#:use-module (goblins ocapn netlayer testuds)
|
#:use-module (goblins ocapn netlayer onion)
|
||||||
#:export (make-initiator make-joiner ^game-initiator ^game-joiner))
|
#:export (make-initiator make-joiner ^game-initiator ^game-joiner))
|
||||||
|
|
||||||
;;
|
|
||||||
;; Helper to use testuds netlayer
|
|
||||||
;;
|
|
||||||
(define (new-testuds-netlayer)
|
|
||||||
(define tmp "/tmp/netlayers")
|
|
||||||
(unless (access? tmp X_OK) (mkdir tmp))
|
|
||||||
(spawn ^testuds-netlayer tmp))
|
|
||||||
|
|
||||||
;;
|
;;
|
||||||
;; Initiator logic
|
;; Initiator logic
|
||||||
;;
|
;;
|
||||||
(define (make-initiator ^game-controller)
|
(define (make-initiator ^game-controller)
|
||||||
(with-vat (spawn-vat)
|
(with-vat (spawn-vat)
|
||||||
(define initiator (spawn ^game-initiator ^game-controller))
|
(define initiator (spawn ^game-initiator ^game-controller))
|
||||||
(define mycapn (spawn-mycapn (new-testuds-netlayer)))
|
(define mycapn (spawn-mycapn (new-onion-netlayer)))
|
||||||
(define init-sref ($ mycapn 'register initiator 'testuds))
|
(define init-sref ($ mycapn 'register initiator 'testuds))
|
||||||
(format #t "Connect to: ~a\n" (ocapn-id->string init-sref))))
|
(format #t "Connect to: ~a\n" (ocapn-id->string init-sref))))
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue