Created
January 8, 2015 19:02
-
-
Save locnguyen/4ef7eeda8c029c214d10 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. | |
# Every Vagrant virtual environment requires a box to build off of. | |
config.vm.box = "puppetlabs/centos-7.0-64-puppet" | |
# Disable automatic box update checking. If you disable this, then | |
# boxes will only be checked for updates when the user runs | |
# `vagrant box outdated`. This is not recommended. | |
# config.vm.box_check_update = false | |
# Create a forwarded port mapping which allows access to a specific port | |
# within the machine from a port on the host machine. In the example below, | |
# accessing "localhost:8080" will access port 80 on the guest machine. | |
config.vm.network :forwarded_port, guest: 8080, host: 8080 | |
config.vm.network :forwarded_port, guest: 5858, host: 5858 | |
# Create a public network, which generally matched to bridged network. | |
# Bridged networks make the machine appear as another physical device on | |
# your network. | |
config.vm.network :public_network | |
# If true, then any SSH connections made will enable agent forwarding. | |
# Default value: false | |
# config.ssh.forward_agent = true | |
# Share an additional folder to the guest VM. The first argument is | |
# the path on the host to the actual folder. The second argument is | |
# the path on the guest to mount the folder. And the optional third | |
# argument is a set of non-required options. | |
config.vm.synced_folder ".", "/var/www/allthethings", owner: "vagrant", group: "vagrant", mount_options: ["dmode=775","fmode=664"], type: "rsync", rsync__exclude: ".git/" | |
# Provider-specific configuration so you can fine-tune various | |
# backing providers for Vagrant. These expose provider-specific options. | |
# Example for VirtualBox: | |
# | |
config.vm.provider "virtualbox" do |vb| | |
vb.cpus = 2 | |
vb.memory = 512 | |
end | |
config.vm.provision :shell, inline: "yum -y update" | |
config.vm.provision "puppet" do |puppet| | |
puppet.manifests_path = "puppet/manifests" | |
puppet.manifest_file = "default.pp" | |
puppet.module_path = "puppet/modules" | |
end | |
end |
I don't see anything related to the folder sync you mentioned. Just for S&Gs can you try this? config.vm.synced_folder File.dirname(FILE), "/var/www/allthethings"
should be __ + FILE + __ instead of a bold file (just look at it raw)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Output of
vagrant up --debug
INFO interface: info: Configuring and enabling network interfaces...
INFO interface: info: ==> default: Configuring and enabling network interfaces...
==> default: Configuring and enabling network interfaces...
DEBUG ssh: Checking whether SSH is ready...
DEBUG ssh: Re-using SSH connection.
INFO ssh: SSH is ready!
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: (sudo=false)
DEBUG ssh: Exit status: 0
DEBUG guest: Searching for cap: configure_networks
DEBUG guest: Checking in: centos7
DEBUG guest: Found cap: configure_networks in centos7
INFO guest: Execute capability: configure_networks #<Vagrant::Machine: default (VagrantPlugins::ProviderVirtualBox::Provider)>, [{:type=>:dhcp, :use_dhcp_assigned_default_route=>false, :auto_config=>true, :interface=>1}]
DEBUG ssh: Checking whether SSH is ready...
DEBUG ssh: Re-using SSH connection.
INFO ssh: SSH is ready!
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: (sudo=false)
DEBUG ssh: Exit status: 0
DEBUG guest: Searching for cap: network_scripts_dir
DEBUG guest: Checking in: centos7
DEBUG guest: Checking in: redhat
DEBUG guest: Found cap: network_scripts_dir in redhat
INFO guest: Execute capability: network_scripts_dir #<Vagrant::Machine: default (VagrantPlugins::ProviderVirtualBox::Provider)>
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /usr/sbin/biosdevname; echo $? (sudo=true)
DEBUG ssh: stderr: Unknown device type, try passing an option like -i
Usage: biosdevname [options] [args]...
Options:
-i or --interface treat [args] as ethernet devs
-d or --debug enable debugging
-p or --policy [physical | all_ethN ]
-P or --prefix [string] string use for embedded NICs (default='em')
-s or --smbios [x.y] Require SMBIOS x.y or greater
-x or --nopirq Don't use $PIR table for slot numbers
-v or --version Show biosdevname version
Example: biosdevname -i eth0
returns: em1
when eth0 is an embedded NIC with label '1' on the chassis.
You must be root to run this, as it must read from /dev/mem.
DEBUG ssh: Exit status: 0
DEBUG ssh: stdout: 1
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /usr/sbin/biosdevname -d | grep Kernel | cut -f2 -d: | sed -e 's/ //;' (sudo=true)
DEBUG ssh: stdout: enp0s3
enp0s8
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /usr/sbin/biosdevname --policy=all_ethN -i enp0s3 (sudo=true)
DEBUG ssh: stdout: eth0
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /usr/sbin/biosdevname --policy=all_ethN -i enp0s8 (sudo=true)
DEBUG ssh: stdout: eth1
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: touch /etc/sysconfig/network-scripts/ifcfg-enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: sed -e '/^#VAGRANT-BEGIN/,/^#VAGRANT-END/ d' /etc/sysconfig/network-scripts/ifcfg-enp0s8 > /tmp/vagrant-ifcfg-enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: cat /tmp/vagrant-ifcfg-enp0s8 > /etc/sysconfig/network-scripts/ifcfg-enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: rm -f /tmp/vagrant-ifcfg-enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Uploading: /var/folders/y7/mn6_c9b94yd_k9nw2m5207sh0000gn/T/vagrant20150108-770-qupct2 to /tmp/vagrant-network-entry_enp0s8
DEBUG ssh: Re-using SSH connection.
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: cat /tmp/vagrant-network-entry_enp0s8 >> /etc/sysconfig/network-scripts/ifcfg-enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /sbin/ifdown enp0s8 (sudo=true)
DEBUG ssh: Exit status: 0
DEBUG ssh: Re-using SSH connection.
INFO ssh: Execute: /sbin/ifup enp0s8 (sudo=true)
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: Sending SSH keep-alive...
DEBUG ssh: stderr: Error: Timeout 90 sec expired.
DEBUG ssh: Exit status: 3
INFO retryable: Retryable exception raised: #<Vagrant::Errors::VagrantError: The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
/sbin/ifup enp0s8
Stdout from the command:
Stderr from the command:
Error: Timeout 90 sec expired.