postinstall changes

This commit is contained in:
Micah R Ledbetter 2015-10-07 14:27:04 -05:00
parent 776a5f7744
commit ab297178c1
2 changed files with 2 additions and 10 deletions

View File

@ -4,10 +4,10 @@ param()
import-module $PSScriptRoot\wintriallab-postinstall.psm1
try {
#Enable-WinRM
Set-PasswordExpiry -accountName "vagrant" -expirePassword $false
Disable-HibernationFile
Enable-MicrosoftUpdate
#Enable-WinRM
}
catch {
write-host "======== CAUGHT EXCEPTION ========"

View File

@ -6,7 +6,7 @@ Don't require parameters - it won't run with parameters during post install. Thi
param(
$packerBuildName = ${env:PACKER_BUILD_NAME},
$packerBuilderType = ${env:PACKER_BUILDER_TYPE},
$tempDir = ${env:WinTrialLabTemp} # calculated later on if this is empty
$tempDir # calculated later on if this is empty
)
$errorActionPreference = "stop"
@ -20,8 +20,6 @@ if ($packerBuilderType -notmatch "virtualbox") {
$LASTEXITCODE = 0 # just in case
# Wrap all my function calls in try/finally to remove the temp dir
if ($tempDir) { $env:WinTrialLabTemp = $tempDir }
import-module $PSScriptRoot\wintriallab-postinstall.psm1
try {
Install-SevenZip
@ -29,7 +27,6 @@ try {
Install-VBoxAdditions -fromDisc
Disable-AutoAdminLogon
Enable-RDP
#Install-VagrantSshKey
Install-Chocolatey
$suoParams = @{
@ -59,8 +56,3 @@ catch {
write-host "======== ========"
exit 666
}
finally {
write-host "THE END"
#rm -recurse -force (Get-LabTempDir)
}