Commit 33b4e7c6 authored by Marc Steffens's avatar Marc Steffens
Browse files

Update deploy_testing.ps1

parent 3d1f1c00
Pipeline #214156 passed with stage
in 5 minutes and 15 seconds
......@@ -53,19 +53,10 @@ foreach ($ahost in $hosts){
$deployFrom = "$projectPath\$deployFolder"
$deployTo = "$deployPath\$projectname"
$script = {
if(Test-Path $dTo){
Remove-Item $dTo -Recurse -Force
Copy-Item $dFrom -Destination $dTo -Recurse
if(Test-Path $deployTo){
Remove-Item $deployTo -Recurse -Force
$cred = (New-Object System.Management.Automation.PSCredential ($CI_USERNAME, (ConvertTo-SecureString $CI_PASSWORD -AsPlainText -Force)))
Invoke-Command -ComputerName $env:COMPUTERNAME -credential $cred -ScriptBlock $script -ArgumentList $deployTo, $deployFrom
Copy-Item $deployFrom -Destination $deployTo -Recurse
Write-Host "Error, could not $status $projectname"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment