Skip to content

Commit

Permalink
Recognize CentOS v AMZN2
Browse files Browse the repository at this point in the history
  • Loading branch information
hoffmang9 committed Apr 8, 2020
1 parent 4ae5578 commit 9959681
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 12 deletions.
31 changes: 21 additions & 10 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ Instead of `chia-start-wallet-ui &` as explained in the [README.md](README.md) y
### Amazon Linux 2

```bash
sudo yum update
sudo yum install python3 git
sudo yum update -y
sudo yum install python3 git -y

git clone https://github.com/Chia-Network/chia-blockchain.git
cd chia-blockchain
Expand All @@ -106,22 +106,33 @@ pip install chia-blockchain==1.0.beta3
### CentOS 7.7 or newer

```bash
sudo yum update
sudo yum install gcc openssl-devel bzip2-devel libffi libffi-devel
sudo yum install libsqlite3x-devel
sudo yum update -y

# Compiling python 3.7 is required on CentOS 7.7
# on 8+ just sudo yum install python3.7
sudo yum install gcc openssl-devel bzip2-devel libffi libffi-devel -y
sudo yum install libsqlite3x-devel -y

# Install python 3.7
wget https://www.python.org/ftp/python/3.7.7/Python-3.7.7.tgz
tar -zxvf Python-3.7.7.tgz ; cd Python-3.7.7
./configure --enable-optimizations; sudo make install; cd ..

# Install npm and node
curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum install nodejs

# Download and install the source version
git clone https://github.com/Chia-Network/chia-blockchain.git
cd chia-blockchain

sh install.sh
. ./activate

# Or install from binary wheels
curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum install -y nodejs

python3.7 -m venv venv
ln -s venv/bin/activate
. ./activate
pip install --upgrade pip
pip install -i https://hosted.chia.net/simple/ miniupnpc==2.0.2 setproctitle==1.1.10 cbor2==5.0.1

pip install chia-blockchain==1.0.beta3
```
10 changes: 8 additions & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,17 @@ if [ `uname` = "Linux" ]; then
if type apt-get; then
# Debian/Ubuntu
sudo apt-get install -y npm
elif type yum; then
# CentOS or AMZN 2
elif type yum && [ ! -f "/etc/redhat-release" ] && [ ! -f "/etc/centos-release" ]; then
# AMZN 2
echo "Installing on Amazon Linux 2"
sudo yum install -y python3 git
curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum install -y nodejs
elif type yum && [ -f /etc/redhat-release ] || [ -f /etc/centos-release ]; then
# CentOS or Redhat
echo "Installing on CentOS/Redhat"
curl -sL https://rpm.nodesource.com/setup_10.x | sudo bash -
sudo yum install -y nodejs
fi
elif [ `uname` = "Darwin" ] && type brew && ! npm version>/dev/null 2>&1; then
# Install npm if not installed
Expand Down

0 comments on commit 9959681

Please sign in to comment.