Skip to content

Commit

Permalink
Add provisioning
Browse files Browse the repository at this point in the history
  • Loading branch information
ixkaito committed Dec 12, 2015
1 parent cd65259 commit c0288a2
Show file tree
Hide file tree
Showing 2 changed files with 65 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,11 @@ Vagrant.configure(2) do |config|
config.vm.synced_folder "./data", "/home/docker/data", create: true

# for NFS synced folder
# config.vm.synced_folder ".", "/vagrant", type: "nfs", mount_options: ["nolock", "vers=3", "udp"]

# for RSync synced folder
# config.vm.synced_folder ".", "/vagrant", type: "rsync", rsync__args: ["--verbose", "--archive", "--delete", "--copy-links"]
# config.vm.synced_folder "./data", "/home/docker/data", create: true, type: "nfs", mount_options: ["nolock", "vers=3", "udp"]

# config.vm.provision :shell, privileged: false, inline: <<-EOS
# curl -O https://raw.githubusercontent.com/wckr/wocker-bashrc/master/bashrc && mv -f bashrc ~/.bashrc && source ~/.bashrc
# docker pull wocker/wocker:latest
# wocker run --name wocker
# EOS
end
59 changes: 59 additions & 0 deletions Vagrantfile.bak
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# -*- mode: ruby -*-
# # vi: set ft=ruby :

require 'fileutils'

Vagrant.require_version ">= 1.6.0"

# Defaults for config options
$update_channel = "stable"
$vb_gui = false
$vb_memory = 1024
$vb_cpus = 1

Vagrant.configure("2") do |config|
# always use Vagrants insecure key
config.ssh.insert_key = false

config.vm.box = "coreos-%s" % $update_channel
config.vm.box_version = ">= 308.0.1"
config.vm.box_url = "http://%s.release.core-os.net/amd64-usr/current/coreos_production_vagrant.json" % $update_channel

["vmware_fusion", "vmware_workstation"].each do |vmware|
config.vm.provider vmware do |v, override|
override.vm.box_url = "http://%s.release.core-os.net/amd64-usr/current/coreos_production_vagrant_vmware_fusion.json" % $update_channel
end
end

config.vm.provider :virtualbox do |vb|
# On VirtualBox, we don't have guest additions or a functional vboxsf
# in CoreOS, so tell Vagrant that so it can be smarter.
vb.check_guest_additions = false
vb.functional_vboxsf = false

vb.gui = $vb_gui
vb.memory = $vb_memory
vb.cpus = $vb_cpus
end

# plugin conflict
# if Vagrant.has_plugin?("vagrant-vbguest")
# config.vbguest.auto_update = false
# end

# if Vagrant.has_plugin?("vagrant-hostsupdater")
# config.hostsupdater.remove_on_suspend = true
# end

# config.vm.hostname = "wocker.dev"
# config.vm.network :private_network, ip: "172.17.8.23"

config.vm.synced_folder "./data", "/home/core/data", create: true, id: "core", nfs: true, mount_options: ['nolock,vers=3,udp']

config.vm.provision :shell, privileged: false, inline: <<-EOS
curl -O https://raw.githubusercontent.com/wckr/wocker-bashrc/master/bashrc && mv -f bashrc ~/.bashrc && source ~/.bashrc
docker pull wocker/wocker:latest
wocker run --name wocker
EOS

end

0 comments on commit c0288a2

Please sign in to comment.