Last active
July 5, 2017 03:48
-
-
Save cutecycle/9b6ebb80b55f1898e34f12272c811bd1 to your computer and use it in GitHub Desktop.
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.box = "ubuntu/xenial64" | |
# config.vm.box_check_update = false | |
# config.vm.network "forwarded_port", guest: 80, host: 8080 | |
#config.vm.network "forwarded_port", guest: 80, host: 8080, host_ip: "127.0.0.1" | |
# config.vm.network "private_network", ip: "192.168.33.10" | |
# config.vm.network "public_network" | |
# config.vm.synced_folder "../data", "/vagrant_data" | |
config.vm.provider "virtualbox" do |vb| | |
# vb.gui = true | |
vb.memory = "768" | |
end | |
# config.push.define "atlas" do |push| | |
# push.app = "YOUR_ATLAS_USERNAME/YOUR_APPLICATION_NAME" | |
# end | |
#config.vm.provision "file", source: "~/.ssh/id_rsa.pub", destination: "~/.ssh/me.pub" | |
#config.ssh.private_key_path = "~/.ssh/id_rsa" | |
config.ssh.forward_agent = true | |
config.vm.provision "shell", inline: " | |
sudo apt-get install software-properties-common | |
sudo apt-add-repository ppa:ansible/ansible | |
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - | |
apt-get update | |
apt-get install -y ansible | |
apt-get install -y ruby | |
gem install ruby-beautify | |
ansible-galaxy install geerlingguy.nodejs | |
ansible-galaxy install ctorgalson.janus | |
ansible-galaxy install geerlingguy.git | |
ansible-galaxy install viasite-ansible.zsh | |
git config --user.email \"[email protected]\" | |
git config --user.name \"Nina Reynolds\" | |
crontab -l > mycron | |
echo \"MAILTO=\"[email protected]\" */5 * * * * ./vagrant/autopush.sh\" >> mycron | |
crontab mycron | |
rm mycron | |
" | |
config.vm.synced_folder ".", "/vagrant" | |
# | |
# Run Ansible from the Vagrant Host | |
# | |
config.vm.provision "ansible_local" do |ansible| | |
ansible.playbook = "/vagrant/playbook.yml" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment