Skip to content

Instantly share code, notes, and snippets.

@rj-reilly
Last active August 29, 2015 14:21
Show Gist options
  • Save rj-reilly/d95e301e4f7d94900bbd to your computer and use it in GitHub Desktop.
Save rj-reilly/d95e301e4f7d94900bbd to your computer and use it in GitHub Desktop.
require 'serverspec'
require 'winrm'
set :backend, :winrm
user = 'vagrant'
pass = 'vagrant'
endpoint = "http://#{ENV['TARGET_HOST']}:55985/wsman"
winrm = ::WinRM::WinRMWebService.new(endpoint, :ssl, :user => user, :pass => pass, :basic_auth_only => true)
winrm.set_timeout 300 # 5 minutes max timeout for any operation
Specinfra.configuration.winrm = winrm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment