Last active
June 17, 2020 11:28
-
-
Save CHTJonas/97714e6c8cc8cf7a11160ba0998f9681 to your computer and use it in GitHub Desktop.
This file contains 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 | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script should be run as root" | |
exit 1 | |
fi | |
# Install build dependencies | |
apt install -y build-essential libssl-dev libreadline-dev zlib1g-dev libmariadb-dev | |
# Install Ruby | |
mkdir -p /opt/embedded | |
git clone https://github.com/rbenv/ruby-build.git /tmp/ruby-build | |
PREFIX=/opt/embedded/ruby-build /tmp/ruby-build/install.sh | |
/opt/embedded/ruby-build/bin/ruby-build 2.6.6 /opt/embedded/ruby | |
rm -rf /tmp/ruby-build | |
# Install NodeJS | |
curl -sSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - | |
echo "deb https://deb.nodesource.com/node_12.x bionic main" | tee /etc/apt/sources.list.d/nodesource.list | |
apt update && apt install -y nodejs | |
# Install Yarn | |
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - | |
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list | |
apt update && apt install -y yarn |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment