Created
February 27, 2017 16:08
-
-
Save rhemz/f20f0f0e5ec644f57205562d9b7a682d to your computer and use it in GitHub Desktop.
openresty vagrantfile
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure(2) do |config| | |
# base config | |
config.vm.box = "janihur/ubuntu-1404-desktop" | |
config.vm.box_check_update = false | |
config.vm.hostname = "proxy6-01-dev" | |
# port forwarding | |
config.vm.network "forwarded_port", guest: 22, host: 22222 | |
config.vm.network "forwarded_port", guest: 80, host: 8880 | |
config.vm.provider "virtualbox" do |vb| | |
vb.gui = true | |
vb.memory = "1536" | |
end | |
# additional provisioning shell commands | |
config.vm.provision "shell", inline: <<-SHELL | |
sudo apt-get update | |
sudo apt-get install -y git build-essential curl libssl-dev zlib1g-dev libbz2-dev libreadline-dev libffi-dev libpcre3 libpcre3-dev redis-server rxvt-unicode | |
wget -O /tmp/openresty.tar.gz https://openresty.org/download/ngx_openresty-1.9.3.1.tar.gz | |
wget -O /tmp/zerobrane-studio.sh https://download.zerobrane.com/ZeroBraneStudioEduPack-1.50-linux.sh | |
chmod +x /tmp/zerobrane-studio.sh | |
# openresty | |
tar xzvf /tmp/openresty.tar.gz -C /tmp/ | |
cd /tmp/ngx_openresty-1.9.3.1/ && ./configure | |
cd /tmp/ngx_openresty-1.9.3.1/ && make | |
cd /tmp/ngx_openresty-1.9.3.1/ && sudo make install | |
# lua ide | |
/tmp/zerobrane-studio.sh | |
# sudo dpkg-reconfigure keyboard-configuration # run this afterwards. this vagrant box defaults to intl keyboard layout | |
SHELL | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment