Closed ti-jalopez closed 3 years ago
If you replace line 1715 in New-NavContainer.ps1 from this:
} -argumentList $zipName, $devcountry
to
} -argumentList (Get-BcContainerPath -containerName $containerName -path $zipName), $devcountry
Then it should work. If you can verify this, I will checkin the fix.
I've tested it and it runs fine 👍 I think the same problem will occur when you are patching for version "14.10.40471.0": https://github.com/microsoft/navcontainerhelper/blob/4e35247976412dcfa71a097386fd1f7c2d6f1b3e/ContainerHandling/New-NavContainer.ps1#L1695-L1701
Best regards,
I've experienced a similar issue lately when using the onprem/16.0.11240.12085/de artifacts. However I discovered the following:
This throws an error when trying to create the image.
New-BCContainer @Parameters `
-doNotCheckHealth `
-updateHosts `
-containerName $containerName `
-artifactUrl $artifactUrl `
-auth "UserPassword" `
-Credential $credential `
-additionalParameters $additionalParameters `
-includeTestToolkit `
-includeTestLibrariesOnly `
-doNotUseRuntimePackages `
-enableTaskScheduler:$false
This creates the image and container without problems, patches the app files and then installs the test libraries.
New-BCContainer @Parameters `
-doNotCheckHealth `
-updateHosts `
-containerName $containerName `
-artifactUrl $artifactUrl `
-auth "UserPassword" `
-Credential $credential `
-additionalParameters $additionalParameters `
-doNotUseRuntimePackages `
-enableTaskScheduler:$false
Import-TestToolkitToBcContainer -containerName $containerName -includeTestLibrariesOnly
So my issue seems to have been that New-BCImage doesn't use the patched apps.
That might be, yes,
Shipped in BcContainerHelper 2.0.0
PLEASE DO NOT INCLUDE ANY PASSWORDS OR TOKENS IN YOUR ISSUE!!!
Describe the issue Create a BCContainer for BC 16.0 including test fails. The error is:
After that, I have been researching in BCContainerHelper source code, and I 've put a breakpoint on https://github.com/microsoft/navcontainerhelper/blob/c31a6ac484d678eae11e65e408ac73899772a377/ContainerHandling/New-NavContainer.ps1#L1713
The full output script show some values of variables after breakpoint enter in Invoke-ScriptInNavContainer.ps1 (see [DBG] on output). I think the problem is caused by I've changed settings for $bcContainerHelperConfig.hostHelperFolder to c:\containerhelper, and the code in https://github.com/microsoft/navcontainerhelper/blob/c31a6ac484d678eae11e65e408ac73899772a377/ContainerHandling/New-NavContainer.ps1#L1708 uses $containerhelper (the folder on host) that is different to the folder inside the container c:\ProgramData\bccontainerhelper.
Scripts used to create container and cause the issue
Full output of scripts
Screenshots If applicable, add screenshots to help explain your problem.
Additional context