Skip to content

Instantly share code, notes, and snippets.

View alansoliditydev's full-sized avatar

Alan The Achiever alansoliditydev

  • NoWhere ;)
View GitHub Profile
#!/bin/bash
exec zsh
nvm install 14.15.0
nvm alias default 14.15.0
exec zsh
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python get-pip.py
pip install supervisor
echo_supervisord_conf > supervisord.conf
cat <<EOF | tee --append supervisord.conf
[program:mining-server]
command=/usr/bin/yarn --cwd /root/Mining-Local-Server start
sudo apt-get install -y build-essential cmake libssl-dev pkg-config
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
echo "source $HOME/.cargo/env" >> ~/.zshrc
exec zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.37.0/install.sh)"
@alansoliditydev
alansoliditydev / pre-setup.sh
Last active December 14, 2020 18:22
Install ZSH
echo "Enable swap up to 4GB ..........."
sudo fallocate -l 4G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo "Enable /swapfile at startup .........."
echo "/swapfile swap swap defaults 0 0" | sudo tee -a /etc/fstab
Verifying my Blockstack ID is secured with the address 1DT463TCSDhke87gyUPz4h2MgU4BBZbHAs https://explorer.blockstack.org/address/1DT463TCSDhke87gyUPz4h2MgU4BBZbHAs
Verifying my Blockstack ID is secured with the address 13Ajmd6LbP2xb4HktsEKKzFTnMPti65BAX https://explorer.blockstack.org/address/13Ajmd6LbP2xb4HktsEKKzFTnMPti65BAX
#!/bin/bash
docker rm $(docker ps -a -f status=exited -q)
docker rmi $(docker images --quiet --filter "dangling=true")
#docker system prune -a
docker system prune -a -f
@alansoliditydev
alansoliditydev / install.sh
Last active April 9, 2019 03:01
Remote desktop on Ubuntu 18.04
#!/bin/bash
echo "Enable swap up to 4GB ..........."
sudo fallocate -l 4G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo "Enable /swapfile at startup .........."
@alansoliditydev
alansoliditydev / interactive
Last active November 16, 2018 11:42
interciy (use with root)
// install intercity
curl https://gist.githubusercontent.com/TranDinhKhang/54447f859b767157165399213d6a2cbb/raw/2bd57bf9776ebcf16a27fe75c9028691d4fcea3d/install%2520intercity | bash
source /root/.bashrc && intercity-server install
// clean up docker image
rm -rf /tmp/*
rm -rf /var/tmp/*
docker ps -a | grep Exit | cut -d ' ' -f 1 | xargs docker rm
docker images | grep "<none>" | cut -d ' ' -f 1 | xargs docker rmi -f
#!/usr/bin/env bash
version=0.2.0
dir_name=intercity-server-${version}-linux-x86_64
file_name=${dir_name}.tar.gz
download_url=https://intercity.io/downloads/linux_x86_64/${file_name}
bin_dir="/var/intercity-cli"
source_line="export PATH=\$PATH:${bin_dir}"