forked from ice00/multi-pool
-
Notifications
You must be signed in to change notification settings - Fork 0
/
startup.sh
executable file
·80 lines (60 loc) · 2 KB
/
startup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#! /bin/sh
# multi-pool startup script
#
# Install the library
#
# by Ice00
#
# (C) 2014 Ice Team
#
# Directory structure:
#
# /opt/multi-pool/
# script/ multi-pool script
# coin/ coin definitions (each subdirectory=a coin sigle)
# bin/ binary of daemon
# src/ source of daemon (each subdirectory=a coin sigle)
# mpos/ mpos (each directory=a coin sigle)
# statum/ statum (each directory=a coin sigle)
# wallet/ wallet (each directory=a coin sigle)
BASE_DIR=/opt/multi-pool
mkdir $BASE_DIR
# make all the tree
mkdir $BASE_DIR/coin
mkdir $BASE_DIR/bin
mkdir $BASE_DIR/src
mkdir $BASE_DIR/mpos
mkdir $BASE_DIR/stratum
mkdir $BASE_DIR/wallet
mkdir $BASE_DIR/script
# copy all the stuff exatracted from the zip to script directory
cp * $BASE_DIR/script
# update the server
sudo apt-get update
sudo apt-get dist-upgrade
# install the library
sudo apt-get install git mysql-server
sudo apt-get install build-essential libboost-all-dev libcurl4-openssl-dev libdb5.3-dev libdb5.3++-dev libssl-dev
# add specific library
#sudo apt-getapt-get install libboost1.48-all-dev
# statum mining
sudo apt-get install python-twisted python-mysqldb python-dev python-setuptools python-memcache python-simplejson python-pylibmc
easy_install -U distribute
# mpos library
sudo apt-get install memcached php5-memcached php5-mysqlnd php5-curl php5-json libapache2-mod-php5
sudo apache2ctl -k stop; sleep 2; sudo apache2ctl -k start
# add mail server
sudo apt-get install postfix
# install stratum and litecoin
cd $BASE_DIR/stratum
git clone https://github.com/Tydus/litecoin_scrypt.git
git clone https://github.com/ahmedbodi/stratum.git
git clone https://github.com/scr34m/vertcoin_scrypt
cd $BASE_DIR/stratum/litecoin_scrypt
python setup.py install
cd $BASE_DIR/stratum/stratum
python setup.py install
cd $BASE_DIR/stratum/vertcoin_scrypt
python setup.py install
groupadd coind
useradd coind -d /opt/multi-pool/bin -s /bin/false -g coind