After using the xWebDeploy resource twice I discovered that it only sees files that were added or deleted. Updated files are not detected. And because of that the webdeploy command to sync the package with the target folder/IIS site is not executed.
I think this is because of this code from xWebPackageDeploy.psm1:
if($Ensure -eq "Present")
{
#find all the files for a given site
$siteFiles = & $appCmd -verb:dump "-source:contentPath=$Destination"
# the packages exported using webdeploy tool, contain 2 extra entries with site name. Skipping those..
#compare based on the number of files
if(($packageFiles.Count -eq $siteFiles.Count) -or (($packageFiles.Count -2) -eq $siteFiles.Count) )
{
$result = $true
}
}
After using the
xWebDeploy
resource twice I discovered that it only sees files that were added or deleted. Updated files are not detected. And because of that the webdeploy command to sync the package with the target folder/IIS site is not executed.I think this is because of this code from
xWebPackageDeploy.psm1
:I would expect something like:
The problem is however that this command doesn't return a very usable result for powershell to process.
If anyone knows a better way to deal with updated files, I'm all ears!