Skip to content

Instantly share code, notes, and snippets.

@robnolen
Created May 8, 2012 23:44
Show Gist options
  • Save robnolen/2640447 to your computer and use it in GitHub Desktop.
Save robnolen/2640447 to your computer and use it in GitHub Desktop.
file {'c:/fix_winrm.ps1':
ensure => present,
source => 'puppet://puppet.convention.con/modules/fix_winrm/fix_winrm.ps1'
owner => 'Administrator',
group => 'Administrators',
mode => 0770,
}
exec {'fix_winrm':
command => 'cmd /c C:\Windows\System32\WindowsPowerShell\v1.0\PowerShell.exe -ExecutionPolicy Unrestricted c:\fix_winrm.ps1'
logoutput => true,
require => File['c:/fix_winrm.ps1'],
before => File['delete_fixwinrm_ps1'],
}
file {'delete_fixwinrm_ps1':
ensure => absent,
path => 'c:/fix_winrm.ps1',
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment