1 个稳定版本
2.1.0 | 2020年5月25日 |
---|---|
1.9.0 |
|
0.9.0 |
|
#21 in #维护
每月下载次数 32
20KB
192 行
darwinia-sync
设置
- 使用 crates.io
cargo install darwinia-sync
- 从源码编译
git clone https://github.com/AurevoirXavier/darwinia-sync.git cd darwinia-sync cargo build --release cp target/release/darwinia-sync ~/.local/bin # or somewhere in your $PATH
用法
运行示例
# normal
darwinia-sync -l -s /home/xavier/crab/crab.sh
# pm2
pm2 start darwinia-sync -- -l -s /home/xavier
# systemd
systemctl start crab.service
crab.sh
脚本示例
/home/xavier/crab/darwinia \
--unsafe-rpc-external \
--unsafe-ws-external \
--validator \
--base-path /home/xavier/crab/data/xavier \
--name Xavier \
--rpc-cors all
crab.service
系统d 示例
[Unit]
Description=Crab
[Service]
ExecStart=/home/xavier/.cargo/bin/darwinia-sync -l -s /home/xavier/crab/crab.sh
Restart=always
RestartSec=3
[Install]
WantedBy=multi-user.target
帮助
λ darwinia-sync --help
darwinia-sync 0.7.0
Xavier Lau <c.estlavie@icloud>
Darwinia Maintain Tool
USAGE:
darwinia-sync [FLAGS] [OPTIONS]
FLAGS:
-l, --log Syncing Log
-h, --help Prints help information
-V, --version Prints version information
OPTIONS:
-s, --script <PATH> Darwinia Boot Script
依赖项
~6–14MB
~167K SLoC