aboutsummaryrefslogtreecommitdiffstats
path: root/config/shepherd/init.d/bitcoin.scm
diff options
context:
space:
mode:
Diffstat (limited to 'config/shepherd/init.d/bitcoin.scm')
-rw-r--r--config/shepherd/init.d/bitcoin.scm82
1 files changed, 41 insertions, 41 deletions
diff --git a/config/shepherd/init.d/bitcoin.scm b/config/shepherd/init.d/bitcoin.scm
index 2805b57..a010bb4 100644
--- a/config/shepherd/init.d/bitcoin.scm
+++ b/config/shepherd/init.d/bitcoin.scm
@@ -2,11 +2,6 @@
(use-modules (ice-9 popen)
(ice-9 rdelim))
-(define (make-dir-parents dir-path)
- (unless (access? dir-path F_OK)
- (make-dir-parents (dirname dir-path))
- (mkdir dir-path)))
-
(define (bitcoin-rpc-pass)
(let* ((port
(open-input-pipe
@@ -18,44 +13,49 @@
;; TESTNET
;; Requires the running node which is now under systemd
(register-services
- (make <service>
- #:docstring "Bitcoin testnet index"
- #:provides '(index-testnet)
- #:start (make-forkexec-constructor
- (list "/home/titan/dev/bitcoin/rust-bitcoin-indexer/target/release/bitcoin-indexer")
- #:environment-variables `("DATABASE_URL=postgres://titan@%2Frun%2Fpostgresql/btc-testnet-idx"
- ,(format #f "NODE_RPC_URL=http://crazy:~a@127.0.0.1:18332/" (bitcoin-rpc-pass))
- "RUST_LOG=bitcoin_indexer=info")
- #:log-file "/tmp/btc-indexer.log")
- #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
- #:respawn? #t))
+ (service
+ '(index-testnet)
+ #:documentation "Bitcoin testnet index"
+ #:start (make-forkexec-constructor
+ (list "/home/titan/dev/bitcoin/rust-bitcoin-indexer/target/release/bitcoin-indexer")
+ #:environment-variables `("DATABASE_URL=postgres://titan@%2Frun%2Fpostgresql/btc-testnet-idx"
+ ,(format #f "NODE_RPC_URL=http://crazy:~a@127.0.0.1:18332/" (bitcoin-rpc-pass))
+ "RUST_LOG=bitcoin_indexer=info")
+ #:log-file "/tmp/btc-indexer.log")
+ #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
+ #:respawn? #t))
(register-services
- (make <service>
- #:docstring "Bitcoin testnet lnd lightning"
- #:provides '(lnd-testnet)
- #:start (make-forkexec-constructor
- (list "/home/titan/.local/bin/lnd"
- "--lnddir=/run/media/titan/ext_backup/personal/bitcoin/lnd/"
- "--noseedbackup"))
- #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
- #:respawn? #t))
+ (service
+ '(lnd-testnet)
+ #:documentation "Bitcoin testnet lnd lightning"
+ #:start (make-forkexec-constructor
+ (list "/home/titan/.local/bin/lnd"
+ "--lnddir=/run/media/titan/ext_backup/personal/bitcoin/lnd/"
+ "--noseedbackup"))
+ #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
+ #:respawn? #t))
;; ssh
(register-services
- (make <service>
- #:docstring "Sarah ssh tunnel"
- #:provides '(sarah-ssh)
- #:start (make-forkexec-constructor
- (list "ssh" "-NTv"
- "-o" "ServerAliveInterval=60"
- "-o" "ExitOnForwardFailure=yes"
- "-o" "StreamLocalBindUnlink=yes"
- "-L" "8335:localhost:8332" ;; btcm
- "-L" "18335:localhost:18332" ;; btct
- "-L" "8481:localhost:8480" ;; LNDT
- "orchest@sarah")
- #:log-file "/tmp/sarah-ssh.log"
- #:environment-variables '("SSH_AUTH_SOCK=/run/user/1000/gnupg/S.gpg-agent.ssh"))
- #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
- #:respawn? #t))
+ (service
+ '(nina-ssh)
+ #:documentation "nina ssh tunnel"
+ #:start (make-forkexec-constructor
+ (list "ssh" "-NTv"
+ "-o" "ServerAliveInterval=60"
+ "-o" "ExitOnForwardFailure=yes"
+ "-o" "StreamLocalBindUnlink=yes"
+ "-L" "8335:localhost:8332" ;; btcm
+ "-L" "18335:localhost:18332" ;; btct
+ "-L" "8481:localhost:8480" ;; LNDT
+ ;; "-L" "/tmp/nina-mn.socket:/run/cardano-node-mainnet/socket"
+ ;; "-L" "/tmp/nina-pr.socket:/run/cardano-node-preview/socket"
+ ;; "-L" "54320:localhost:5432"
+ ;; "-L" "50001:localhost:50001" ;; electrs
+ ;; "-L" "24224:localhost:24224" ;; electrs monitoring
+ "orchest@nina")
+ #:log-file "/tmp/nina-ssh.log"
+ #:environment-variables '("SSH_AUTH_SOCK=/run/user/1000/gnupg/S.gpg-agent.ssh"))
+ #:stop (make-kill-destructor 2) ;; 2 is SIGINT - interupt process stream, ctrl-C
+ #:respawn? #t))