#download file from repo
download_file { 'Download dotnet 4.0' :
url => 'https://repos.shivaprogramming.com/Myapp.ZIP',
destination_directory => 'D:\downloadapp',
}
#extract zip
exec { 'Unzip Folder':
command =>'Expand-Archive -Path D:\downloadapp\Myapp.ZIP -DestinationPath D:\downloadapp\DEST',
provider => powershell,
logoutput => true,
subscribe => Download_file['Download dotnet 4.0'],
}
#copy resources to the destination
file { 'D:\CA_Websites\MyApp': #destination
ensure => 'directory',
recurse => true,
source => 'D:\downloadapp\DEST',
subscribe => Exec['Unzip Folder'],
}