I am running into an issue where winrm seems to be timing out way too soon. It keeps giving me the following error, however I have an ip address for the guest machine.
# -*- mode: ruby -*-
# vi: set ft=ruby :
require_relative 'tools'
# kinda like a static value in other languages, all caps mean the same.
VAGRANT_INSTANCE_NAME = "vagrant-build"
PRIMARY = false
P_HOST = false
P_DS = false
P_TEMP = false
P_RESOURCE = false
# 2 GB of ram
RAM = 4 * 1024
# 2 processors for the vm
CPUS = 4
Vagrant.configure(2) do |config|
# make sure the proper plugins are available to the host machine.
plugins?
# tell vagrant how we are going to communicate.
config.vm.communicator = 'winrm'
if PRIMARY
config.winrm.username = '<REDACTED>'
config.winrm.password = '<REDACTED>'
end
config.vm.boot_timeout = 1800
config.vm.guest = :windows
config.vm.synced_folder ".", "/vagrant", disabled: true
config.vm.define VAGRANT_INSTANCE_NAME do |d|
# give the box a hostname
d.vm.hostname = VAGRANT_INSTANCE_NAME
d.vm.network 'private_network', ip: '10.4.9.154'
# tell the system where to find the dummy.box
d.vm.box = 'dummy'
d.vm.box_url = './files/dummy.box'
# define the network ip address.
# start setting up the box using the provider installation.
d.vm.provider :vsphere do |vsphere, override|
override.nfs.functional = false
vsphere.user = '<REDACTED>'
vsphere.password = '<REDACTED>'
vsphere.vlan = 'vDS_TEST 10.4.9.0 %2f24'
vsphere.vm_base_path = 'Development/DEV Automation'
vsphere.resource_pool_name = 'DEV Automation'
vsphere.data_store_name = P_DS ? 'NEXSAN-DEV-01' : 'DevTest-01'
vsphere.template_name = P_TEMP ? 'Development/DEV Automation/WIN2012R2-DEV-Template' : 'Development/DEV Automation/packer_vm_chef'
vsphere.compute_resource_name = P_RESOURCE ? 'Test-Cluster' : 'Vagrant-Cluster'
vsphere.insecure = true
vsphere.memory_mb = RAM
vsphere.cpu_count = CPUS
# vsphere.addressType = 'Generated'
vsphere.customization_spec_name = 'IP_Spec'
end
end
end