How to Install Blockstack Core on your local computer step by step

There are three supported methods to install Blockstack Core:
 
  • source
  • pip
  • docker

 
Install from Source:
 Before installing Blockstack Core from source, you will need to install libffi-dev and libssl-dev. Mac and Linux users can usually grab these packages from their respective package managers.
Once these dependencies are installed, you can install Blockstack Core from source via the included setup.py script, as follows:
 
$ git clone [url=https://github.com/blockstack/blockstack-core]https://github.com/blockstack/blockstack-core[/url]
$ cd blockstack-core
$ python2 ./setup.py build
$ sudo python2 ./setup.py install

 You can also use a virtualenv to install Blockstack Core in a non-system directory.
Install with pip:
 NOTE: Using pip is only supported for stable releases (i.e. master).
Blockstack is built against Python 2.7. You should use pip2 if you have it instead of pip. If you do not have pip2, you should verify that your pip is configured for Python 2.
 
On Mac:
 
# Install blockstack
$ pip install blockstack --upgrade
 
 
On CentOS 7 & RHEL:
 
# Install dependencies
$ yum install epel-release
$ yum install python-pip python-devel openssl-devel libffi-devel rng-tools gmp-devel zlib-devel

# Install blockstack
$ sudo pip install blockstack --upgrade

 
You will need to open ports TCP:6264 and TCP:6270. If you have trouble starting blockstack-core, you can try disabling SELinux and/or firewalld as follows:
 
# Disable SELinux
$ setenforce 0
$ sed -i --follow-symlinks 's/^SELINUX=.*/SELINUX=disabled/g' /etc/sysconfig/selinux && cat /etc/sysconfig/selinux
# Stop firewalld
$ systemctl stop firewalld && systemctl disable firewalld
 
 
On Debian & Ubuntu:
 # Install dependancies
$ sudo apt-get update && sudo apt-get install -y python-pip python-dev libssl-dev libffi-dev rng-tools libgmp3-dev
$ sudo pip install pyparsing


# Install blockstack
$ sudo pip install blockstack --upgrade

Install with docker:
 NOTE: Using docker is only supported for stable releases (i.e. master).
Another way to run blockstack-core is through docker. We provide per-commit image builds of this repository that are available on quay.io.
 
$ git clone [email protected]:blockstack/blockstack-core.git
$ cd blockstack-core
$ docker build -t blockstack-core:master .
 
# create directory to store Blockstack Core state
 
$ export BLOCKSTACK_DIR="/var/blockstack-core-data"
$ mkdir -p "$BLOCKSTACK_DIR"
$ docker run \
-v $BLOCKSTACK_DIR:/root/.blockstack-server \
-p 6264:6264 \
-p 6270:6270 \
blockstack-core:master

 
 These commands will fast-sync and run a Blockstack Core node in about 10 minutes. The state for the Blockstack Core node will be stored to $BLOCKSTACK_DIR. You can see the node's logs with docker logs -f or with tail -f "$BLOCKSTACK_DIR/blockstack-server.log".
Notes:
* This method is currently only fully supported on Linux.
* You will need sudo access to run the above scripts, and/or be a member of the docker group.
* You can run more than one instance of this setup per host. Allow at least 1 CPU core for each container
* To configure a different bitcoind node, you must edit your blockstack-server.ini file before running the ./docker-tools.sh init-* commands. After init-* has been run you must edit the data/core/server/blockstack-server.ini to change those settings.

 
0
Donate 26-06-19

0 comments

If you wanna get more accurate answers,Please Login or Register