Last active
          November 28, 2019 13:25 
        
      - 
      
 - 
        
Save UbuntuEvangelist/387e14b1479cf700615c5b49483957b9 to your computer and use it in GitHub Desktop.  
    Peatio Microkube Install Linux
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | #!/bin/bash | |
| COMPOSE_VERSION="1.25.0" | |
| COMPOSE_URL="https://github.com/docker/compose/releases/download/$COMPOSE_VERSION/docker-compose-$(uname -s)-$(uname -m)" | |
| # Microkube bootstrap script | |
| install_core() { | |
| sudo bash <<EOS | |
| apt-get update | |
| apt-get upgrade -y -q | |
| apt-get install -y -q git tmux dirmngr dbus htop curl libmariadbclient-dev-compat build-essential | |
| EOS | |
| } | |
| # Docker installation | |
| install_docker() { | |
| curl -fsSL https://get.docker.com/ | bash | |
| sudo bash <<EOS | |
| usermod -aG docker $USER | |
| curl -L "$COMPOSE_URL" -o /usr/local/bin/docker-compose | |
| chmod +x /usr/local/bin/docker-compose | |
| EOS | |
| } | |
| create_user() { | |
| sudo bash <<EOS | |
| groupadd app | |
| useradd --create-home --home /home/app --shell /bin/bash \ | |
| --gid app --groups docker,google-sudoers app | |
| EOS | |
| } | |
| install_ruby() { | |
| sudo -u app bash <<EOS | |
| gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB | |
| curl -sSL https://get.rvm.io | bash -s stable | |
| EOS | |
| } | |
| install_microkube() { | |
| sudo -u app bash <<EOS | |
| cd /home/app | |
| source /home/app/.rvm/scripts/rvm | |
| rvm install --quiet-curl 2.6.0 | |
| rvm use --default 2.6.0 | |
| gem install bundler | |
| git clone https://github.com/SchoolOfFreelancing/Crypto-Bazzar.git | |
| cd Crypto-Bazzar | |
| cp $HOME/app.yml config/ | |
| bundle install | |
| rake render:config | |
| rake service:all | |
| rake service:daemons | |
| rake geth:import | |
| rake service:cryptonodes | |
| ./bin/install_webhook | |
| EOS | |
| } | |
| install_core | |
| install_docker | |
| create_user | |
| install_ruby | |
| install_microkube | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment