Last active
July 6, 2018 04:26
-
-
Save yihyang/0186b3b0817f8ea4f0014ea3380e661a to your computer and use it in GitHub Desktop.
Docker Cloud9 Setup Script, run it using
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
| # run it using bash <(curl https://gist.githubusercontent.com/yihyang/0186b3b0817f8ea4f0014ea3380e661a/raw) | |
| ########## | |
| # docker # | |
| ########## | |
| # setup docker | |
| docker run -it -d -p 80:80 kdelfour/cloud9-docker | |
| ######## | |
| # ruby # | |
| ######## | |
| # install the dependencies required for rbenv and Ruby | |
| sudo apt-get -y install autoconf bison build-essential libssl-dev libyaml-dev libreadline6-dev zlib1g-dev libncurses5-dev libffi-dev libgdbm3 libgdbm-dev | |
| # install rbenv | |
| git clone https://github.com/rbenv/rbenv.git ~/.rbenv | |
| # adding PATH | |
| echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc | |
| echo 'eval "$(rbenv init -)"' >> ~/.bashrc | |
| # source the installed rbenv | |
| source ~/.bashrc | |
| # install ruby version | |
| rbenv install 2.5.1 | |
| rbenv global 2.5.1 | |
| ######### | |
| # NGINX # | |
| ######### | |
| # install nginx | |
| sudo apt-get update | |
| sudo apt-get -y install nginx | |
| # allowing nginx http access | |
| sudo ufw allow 'Nginx HTTP' | |
| systemctl status nginx |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment