Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- # https://bitcointalk.org/index.php?topic=2799605.msg
- # NOTE: You need to set your DNS server address below.
- # Don't just hammer Google's servers when your ISP has
- # already provided the infrastructure.
- DNS=""
- [ $# -lt 5 ] && {
- echo "Usage: $0 workername1 workername2 workername3 hostname ip"
- exit 1
- }
- mv /config/bmminer.conf /config/bmminer.conf.backup
- mv /config/network.conf /config/network.conf.backup
- cat <<EOF >/config/bmminer.conf
- {
- "pools" : [ {
- "url" : "stratum.antpool.com:3333",
- "user" : "test.$1",
- "pass" : "123"
- },
- {
- "url" : "stratum.antpool.com:3333",
- "user" : "test.$2",
- "pass" : "123"
- },
- {
- "url" : "stratum.antpool.com:3333",
- "user" : "test.$3",
- "pass" : "123"
- } ],
- "api-listen" : "true",
- "api-network" : "true",
- "api-groups" : "A:stats:pools:devs:summary:version",
- "api-allow" : "A:0/0,W:*",
- "bitmain-use-vil" : "true",
- "bitmain-freq" : "550",
- "bitmain-voltage" : "0706",
- "multi-version" : "1"
- }
- EOF
- chmod 400 /config/bmminer.conf
- cat <<EOF > /config/network.conf
- hostname=miner$4
- ipaddress=10.0.0.$5
- netmask=255.255.255.0
- gateway=10.0.0.138
- dnsservers="$DNS"
- EOF
- chmod 400 /config/network.conf
- #/etc/init.d/bmminer.sh restart >/dev/null 2>&1
- #/etc/init.d/network.sh
- #/etc/init.d/avahi restart > /dev/null
- #echo "root:antMiner Configuration:23c2a2d78c0d20ec069097d7d20c4392" >> /config/lighttpd-htdigest.user
- exit 0
Add Comment
Please, Sign In to add comment