microsoft / navcontainerhelper

Official Microsoft repository for BcContainerHelper, a PowerShell module, which makes it easier to work with Business Central Containers on Docker.
MIT License
384 stars 247 forks source link

Invalid container creation for BC14 container #1980

Closed sirhc101 closed 3 years ago

sirhc101 commented 3 years ago

Describe the issue I've a customer, using BC 14.24, and we want to setup CI/CD for their development process. We need to do some specific stuff, therefor we created our own scripts to do so, based on BcContainerHelper.

Unfortunately something goes very wrong and I cannot figure out what's going on. Hope you can help.

The script results in a container image which is labeled true:onprem-14.24.46857.0-de and it seems that further usage of the container is not possible. Additionally further cmds like Compile-AppInBcContainer failed, due to the "true" in the label. Get-BcContainerPlatformversion -containerOrImageName $containerName returns only true and Compile-AppInBcContainer failed because "true" is no valid version.

It also fails even to import C/AL objects (fob files)

Scripts used to create container and cause the issue

New-BcContainer `
    -accept_eula $true `
    -accept_outdated $true `
    -artifactUrl $artifact `
    -containerName $containerName `
    -auth NavUserPassword `
    -Credential $credential `
    -includeCSide `
    -licenseFile $licenseFile.FullName `
    -memoryLimit "4G" `
    -updateHosts `
    -enableSymbolLoading `
    -useBestContainerOS

Write-Host "Importing C/AL object dependencies . . . "
Get-ChildItem -Path ".devOps\.dependencies" -Recurse -Filter "*.fob" | ForEach-Object {
    Write-Host $("`t -" + $_.Name)

    Import-ObjectsToNavContainer `
        -containerName $containerName `
        -objectsFile $_.FullName `
        -ImportAction Overwrite `
        -SynchronizeSchemaChanges No `
        -suppressBuildSearchIndex
}

Invoke-ScriptInBcContainer -containerName $containerName -scriptblock {
    Sync-NavTenant -ServerInstance NAV -Mode Sync -Force
}

Full output of scripts

2021-06-28T12:36:31.1284958Z ##[debug]Evaluating condition for step: 'Create Container'
2021-06-28T12:36:31.1288117Z ##[debug]Evaluating: succeeded()
2021-06-28T12:36:31.1289083Z ##[debug]Evaluating succeeded:
2021-06-28T12:36:31.1290851Z ##[debug]=> True
2021-06-28T12:36:31.1291780Z ##[debug]Result: True
2021-06-28T12:36:31.1292787Z ##[section]Starten: Create Container
2021-06-28T12:36:31.1308303Z ==============================================================================
2021-06-28T12:36:31.1309106Z Task         : PowerShell
2021-06-28T12:36:31.1309719Z Description  : Führen Sie ein PowerShell-Skript unter Windows, macOS oder Linux aus.
2021-06-28T12:36:31.1310287Z Version      : 2.140.2
2021-06-28T12:36:31.1310761Z Author       : Microsoft Corporation
2021-06-28T12:36:31.1311416Z Help         : [Weitere Informationen](https://go.microsoft.com/fwlink/?LinkID=613736)
2021-06-28T12:36:31.1312109Z ==============================================================================
2021-06-28T12:36:31.9198509Z ##[debug]VstsTaskSdk 0.11.0 commit 7ff27a3e0bdd6f7b06690ae5f5b63cb84d0f23f4
2021-06-28T12:36:32.0308574Z ##[debug]Entering C:\agent\_work\_tasks\PowerShell_e213ff0f-5d5c-4791-802d-52ea3e7be1f1\2.140.2\powershell.ps1.
2021-06-28T12:36:32.0396445Z ##[debug]Loading resource strings from: C:\agent\_work\_tasks\PowerShell_e213ff0f-5d5c-4791-802d-52ea3e7be1f1\2.140.2\task.json
2021-06-28T12:36:32.0663693Z ##[debug]Loaded 11 strings.
2021-06-28T12:36:32.0713020Z ##[debug]SYSTEM_CULTURE: 'de-DE'
2021-06-28T12:36:32.0736665Z ##[debug]Loading resource strings from: C:\agent\_work\_tasks\PowerShell_e213ff0f-5d5c-4791-802d-52ea3e7be1f1\2.140.2\Strings\resources.resjson\de-DE\resources.resjson
2021-06-28T12:36:32.0993332Z ##[debug]Loaded 11 strings.
2021-06-28T12:36:32.1241599Z ##[debug]INPUT_ERRORACTIONPREFERENCE: 'stop'
2021-06-28T12:36:32.1279464Z ##[debug]INPUT_FAILONSTDERR: 'false'
2021-06-28T12:36:32.1322737Z ##[debug] Converted to bool: False
2021-06-28T12:36:32.1354174Z ##[debug]INPUT_IGNORELASTEXITCODE: 'false'
2021-06-28T12:36:32.1370615Z ##[debug] Converted to bool: False
2021-06-28T12:36:32.1391864Z ##[debug]INPUT_PWSH: 'false'
2021-06-28T12:36:32.1407977Z ##[debug] Converted to bool: False
2021-06-28T12:36:32.1435709Z ##[debug]INPUT_WORKINGDIRECTORY: 'C:\agent\_work\1\s'
2021-06-28T12:36:32.1556836Z ##[debug]Asserting container path exists: 'C:\agent\_work\1\s'
2021-06-28T12:36:32.1580408Z ##[debug]INPUT_TARGETTYPE: 'filePath'
2021-06-28T12:36:32.1613554Z ##[debug]INPUT_FILEPATH: 'C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1'
2021-06-28T12:36:32.1633138Z ##[debug]Asserting leaf path exists: 'C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1'
2021-06-28T12:36:32.1671521Z ##[debug]INPUT_ARGUMENTS (empty)
2021-06-28T12:36:32.1733518Z Skript wird erstellt.
2021-06-28T12:36:32.1797389Z Formatierter Befehl: . 'C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1'
2021-06-28T12:36:32.2451218Z ##[debug]AGENT_VERSION: '2.165.0'
2021-06-28T12:36:32.2544016Z ##[debug]AGENT_TEMPDIRECTORY: 'C:\agent\_work\_temp'
2021-06-28T12:36:32.2560004Z ##[debug]Asserting container path exists: 'C:\agent\_work\_temp'
2021-06-28T12:36:32.2722633Z ##[debug]Asserting leaf path exists: 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe'
2021-06-28T12:36:32.2834744Z ##[debug]Entering Invoke-VstsTool.
2021-06-28T12:36:32.2940033Z ##[debug] Arguments: '-NoLogo -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command ". 'C:\agent\_work\_temp\01aca315-1cd3-40ff-b6d7-ffd05aadcab7.ps1'"'
2021-06-28T12:36:32.2958615Z ##[debug] FileName: 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe'
2021-06-28T12:36:32.2976128Z ##[debug] WorkingDirectory: 'C:\agent\_work\1\s'
2021-06-28T12:36:32.3024704Z ##[command]"C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command ". 'C:\agent\_work\_temp\01aca315-1cd3-40ff-b6d7-ffd05aadcab7.ps1'"
2021-06-28T12:36:32.5942286Z ##[debug]Processed: ##vso[task.setvariable variable=appBuild]20210628
2021-06-28T12:36:32.5944935Z ##[debug]Processed: ##vso[task.setvariable variable=appRevision]27
2021-06-28T12:36:32.5995050Z App Version: 14.24.20210628.27
2021-06-28T12:36:32.6008477Z ##[debug]Update build number for build: 27 to: 14.24.20210628.27 at backend.
2021-06-28T12:36:32.6845921Z ##[debug]Processed: ##vso[build.updatebuildnumber]14.24.20210628.27
2021-06-28T12:36:32.8519652Z BcContainerHelper version 2.0.14
2021-06-28T12:36:35.6890972Z Artifacts found: https://bcartifacts.azureedge.net/onprem/14.24.46857.0/de
2021-06-28T12:36:35.7211847Z License file: BC14_20210615.flf
2021-06-28T12:36:36.6553304Z BcContainerHelper is version 2.0.14
2021-06-28T12:36:36.6559212Z BcContainerHelper is running as administrator
2021-06-28T12:36:36.6580488Z Host is Microsoft Windows Server 2019 Standard - ltsc2019
2021-06-28T12:36:36.7776954Z Docker Client Version is 20.10.5
2021-06-28T12:36:36.7798096Z Docker Server Version is 20.10.5
2021-06-28T12:36:37.1260828Z Downloading application artifact /onprem/14.24.46857.0/de
2021-06-28T12:36:37.1435555Z Downloading C:\Users\navadmin\AppData\Local\Temp\5fa3c50e-6dd3-4b97-9ae4-3479c3badfd4.zip
2021-06-28T12:36:59.7676304Z Unpacking application artifact to tmp folder using Expand-Archive
2021-06-28T12:37:04.9120458Z Downloading platform artifact /onprem/14.24.46857.0/platform
2021-06-28T12:37:04.9139565Z Downloading C:\Users\navadmin\AppData\Local\Temp\2cdb74e6-fb51-419f-88d5-f1d62f6007f3.zip
2021-06-28T12:37:33.9895283Z Unpacking platform artifact to tmp folder using Expand-Archive
2021-06-28T12:38:31.9999156Z Downloading Prerequisite Components
2021-06-28T12:38:32.0203359Z Downloading c:\bcartifacts.cache\onprem\14.24.46857.0\platform\Prerequisite Components\DotNetCore\DotNetCore.1.0.4_1.1.1-WindowsHosting.exe
2021-06-28T12:38:44.1089076Z Downloading c:\bcartifacts.cache\onprem\14.24.46857.0\platform\Prerequisite Components\Open XML SDK 2.5 for Microsoft Office\OpenXMLSDKv25.msi
2021-06-28T12:38:44.4197516Z Downloading c:\bcartifacts.cache\onprem\14.24.46857.0\platform\Prerequisite Components\IIS URL Rewrite Module\rewrite_2.0_rtw_x64.msi
2021-06-28T12:38:45.1390804Z Fetching all docker images
2021-06-28T12:38:45.2518782Z Fetching all docker volumes
2021-06-28T12:38:45.3625118Z ArtifactUrl and ImageName specified
2021-06-28T12:38:45.6458212Z Building image true:onprem-14.24.46857.0-de based on mcr.microsoft.com/businesscentral:10.0.17763.1935 with https://bcartifacts.azureedge.net/onprem/14.24.46857.0/de
2021-06-28T12:38:45.6474666Z Pulling latest image mcr.microsoft.com/businesscentral:10.0.17763.1935
2021-06-28T12:38:46.0189051Z 10.0.17763.1935: Pulling from businesscentral
2021-06-28T12:38:46.0209311Z Digest: sha256:fac203f876f87ace14986b5afbe338dea7abb7c211fad94262e83c5628ac6e4f
2021-06-28T12:38:46.0218021Z Status: Image is up to date for mcr.microsoft.com/businesscentral:10.0.17763.1935
2021-06-28T12:38:46.0281984Z mcr.microsoft.com/businesscentral:10.0.17763.1935
2021-06-28T12:38:46.1620131Z Generic Tag: 1.0.1.7
2021-06-28T12:38:46.2839195Z Container OS Version: 10.0.17763.1935 (ltsc2019)
2021-06-28T12:38:46.2846590Z Host OS Version: 10.0.17763.1935 (ltsc2019)
2021-06-28T12:38:46.2867068Z Using process isolation
2021-06-28T12:38:46.2946748Z Using license file \\xxx\BC14_20210615.flf
2021-06-28T12:38:46.2952815Z Files in c:\bcartifacts.cache\evrzqkf2.bz0\my:
2021-06-28T12:38:46.3001462Z Copying Platform Artifacts
2021-06-28T12:38:49.9872127Z Copying Database
2021-06-28T12:38:50.2874613Z Copying Licensefile
2021-06-28T12:38:50.3325991Z Copying Installers
2021-06-28T12:38:50.3888134Z Copying TestToolKit
2021-06-28T12:38:50.5048309Z Copying UpgradeToolKit
2021-06-28T12:38:50.5440390Z Copying Extensions
2021-06-28T12:38:50.7174933Z c:\bcartifacts.cache\evrzqkf2.bz0
2021-06-28T12:39:01.5415097Z Sending build context to Docker daemon  1.175GB
2021-06-28T12:39:01.5419994Z 
2021-06-28T12:39:01.5974731Z Step 1/6 : FROM mcr.microsoft.com/businesscentral:10.0.17763.1935
2021-06-28T12:39:01.5977959Z  ---> 8f43c1d70fd7
2021-06-28T12:39:01.5981200Z Step 2/6 : ENV DatabaseServer=localhost DatabaseInstance=SQLEXPRESS DatabaseName=CRONUS IsBcSandbox=N artifactUrl=https://bcartifacts.azureedge.net/onprem/14.24.46857.0/de filesOnly=False
2021-06-28T12:39:01.8035389Z  ---> Running in 3c5d80e74401
2021-06-28T12:39:09.6618124Z Removing intermediate container 3c5d80e74401
2021-06-28T12:39:09.6622308Z  ---> 9d60307fa87e
2021-06-28T12:39:09.6626473Z Step 3/6 : COPY my /run/
2021-06-28T12:39:10.4391744Z  ---> 07dce3786312
2021-06-28T12:39:10.4395144Z Step 4/6 : COPY NAVDVD /NAVDVD/
2021-06-28T12:39:45.2528517Z  ---> a9dabc675dcc
2021-06-28T12:39:45.2531143Z Step 5/6 : RUN \Run\start.ps1 -installOnly
2021-06-28T12:39:45.2840053Z  ---> Running in 4f43d81b9af7
2021-06-28T12:39:49.9356603Z Using installer from C:\Run\130
2021-06-28T12:39:50.0771225Z Installing Business Central
2021-06-28T12:39:50.1158311Z Installing Url Rewrite
2021-06-28T12:39:51.6554572Z Installing OpenXML
2021-06-28T12:39:52.7520809Z Installing DotNetCore
2021-06-28T12:39:56.1301943Z Starting Local SQL Server
2021-06-28T12:39:59.2256608Z Starting Internet Information Server
2021-06-28T12:39:59.6163801Z Copying Service Tier Files
2021-06-28T12:40:02.2767694Z Copying Web Client Files
2021-06-28T12:40:06.4293187Z Copying Windows Client Files
2021-06-28T12:40:09.8512102Z Copying PowerShell Scripts
2021-06-28T12:40:09.9246250Z Copying ConfigurationPackages
2021-06-28T12:40:09.9630368Z Copying Test Assemblies
2021-06-28T12:40:09.9952708Z Copying TestToolKit
2021-06-28T12:40:10.4845346Z Copying UpgradeToolKit
2021-06-28T12:40:10.5371083Z Copying Extensions
2021-06-28T12:40:10.6164238Z Copying ClientUserSettings
2021-06-28T12:40:10.9197251Z Copying ReportBuilder
2021-06-28T12:40:33.8037626Z Restoring CRONUS Demo Database
2021-06-28T12:40:33.8335074Z Determining Database Collation
2021-06-28T12:40:34.9734215Z Changing Database Server Collation to Latin1_General_100_CI_AS
2021-06-28T12:41:00.7401800Z Restoring CRONUS Demo Database
2021-06-28T12:41:06.3202215Z Installing C:\NAVDVD\Installers\DE\RTC\RoleTailoredClient.Local.De.msi
2021-06-28T12:41:07.4200225Z Skipping C:\NAVDVD\Installers\DE\WebHelp\WebHelp.Local.De.msi
2021-06-28T12:41:07.4683888Z Modifying Business Central Service Tier Config File for Docker
2021-06-28T12:41:07.5020445Z Creating Business Central Service Tier
2021-06-28T12:41:07.6331295Z Installing SIP crypto provider: 'C:\Windows\System32\NavSip.dll'
2021-06-28T12:41:07.8826427Z Starting Business Central Service Tier
2021-06-28T12:41:41.4472634Z Importing CRONUS license file
2021-06-28T12:41:41.9802291Z Generating Symbol Reference
2021-06-28T12:46:06.0492862Z Stopping Business Central Service Tier
2021-06-28T12:46:06.3243122Z Installation took 376 seconds
2021-06-28T12:46:06.3249537Z Installation complete
2021-06-28T12:47:52.1578251Z Removing intermediate container 4f43d81b9af7
2021-06-28T12:47:52.1579740Z  ---> bcd5f0cc85f9
2021-06-28T12:47:52.1582271Z Step 6/6 : LABEL legal="http://go.microsoft.com/fwlink/?LinkId=837447"       created="202106281238"       nav=""       cu=""       country="de"       version="14.24.46857.0"       platform="14.0.46844.0"
2021-06-28T12:47:52.1868857Z  ---> Running in fb5b7fffaad0
2021-06-28T12:47:59.9991888Z Removing intermediate container fb5b7fffaad0
2021-06-28T12:47:59.9995377Z  ---> 5e17128d91f1
2021-06-28T12:48:00.8953987Z Successfully built 5e17128d91f1
2021-06-28T12:48:00.9072250Z Successfully tagged true:onprem-14.24.46857.0-de
2021-06-28T12:48:00.9248750Z Building image took 555 seconds
2021-06-28T12:48:02.4302173Z Using image true:onprem-14.24.46857.0-de
2021-06-28T12:48:02.6135439Z Creating Container ci
2021-06-28T12:48:02.6143781Z Version: 14.24.46857.0-de
2021-06-28T12:48:02.6152534Z Style: onprem
2021-06-28T12:48:02.6160100Z Multitenant: No
2021-06-28T12:48:02.6168983Z Platform: True
2021-06-28T12:48:02.6178187Z Generic Tag: 1.0.1.7
2021-06-28T12:48:02.6186645Z Container OS Version: 10.0.17763.1935 (ltsc2019)
2021-06-28T12:48:02.6195030Z Host OS Version: 10.0.17763.1935 (ltsc2019)
2021-06-28T12:48:02.6226988Z Using process isolation
2021-06-28T12:48:02.6252308Z Using locale de-DE
2021-06-28T12:48:02.6279406Z Disabling the standard eventlog dump to container log every 2 seconds (use -dumpEventLog to enable)
2021-06-28T12:48:02.6309168Z Using license file \\xxx\BC14_20210615.flf
2021-06-28T12:48:02.7014592Z Files in C:\ProgramData\BcContainerHelper\Extensions\ci\my:
2021-06-28T12:48:02.7128164Z - AdditionalOutput.ps1
2021-06-28T12:48:02.7136538Z - AdditionalSetup.ps1
2021-06-28T12:48:02.7143974Z - license.flf
2021-06-28T12:48:02.7151957Z - MainLoop.ps1
2021-06-28T12:48:02.7160188Z - SetupVariables.ps1
2021-06-28T12:48:02.7167901Z - updatehosts.ps1
2021-06-28T12:48:02.7176008Z Creating container ci from image true:onprem-14.24.46857.0-de
2021-06-28T12:48:02.8783615Z eeb36cf3f00a7ae914da075be7957a909889fde8a77d84e0c5eeb5bcda230620
2021-06-28T12:48:04.6377074Z Waiting for container ci to be ready
2021-06-28T12:48:06.9025088Z Initializing...
2021-06-28T12:48:06.9025837Z Setting host.containerhelper.internal to 172.22.64.1 in container hosts file
2021-06-28T12:48:06.9026317Z Starting Container
2021-06-28T12:48:06.9026838Z Hostname is ci
2021-06-28T12:48:08.0313073Z PublicDnsName is ci
2021-06-28T12:48:09.1589012Z Using NavUserPassword Authentication
2021-06-28T12:48:11.4370582Z Starting Local SQL Server
2021-06-28T12:48:11.4371537Z Starting Internet Information Server
2021-06-28T12:48:12.5764743Z Creating Self Signed Certificate
2021-06-28T12:48:12.5765550Z Self Signed Certificate Thumbprint 4DEB46F8DD9A19740C05DC2D2096A7075604E50F
2021-06-28T12:48:13.7297005Z Modifying Service Tier Config File with Instance Specific Settings
2021-06-28T12:48:50.1929869Z Starting Service Tier
2021-06-28T12:48:50.1931817Z Registering event sources
2021-06-28T12:48:58.3419835Z Creating DotNetCore Web Server Instance
2021-06-28T12:48:58.3424917Z Using license file 'c:\run\my\license.flf'
2021-06-28T12:48:59.6509288Z Import License
2021-06-28T12:49:00.8800065Z Creating http download site
2021-06-28T12:49:02.3979282Z Setting SA Password and enabling SA
2021-06-28T12:49:02.3979932Z Creating admin as SQL User and add to sysadmin
2021-06-28T12:49:02.3980424Z Creating SUPER user
2021-06-28T12:49:02.3980808Z WARNING: The password that you entered does not meet the minimum requirements. 
2021-06-28T12:49:02.3981925Z It should be at least 8 characters long and contain at least one uppercase 
2021-06-28T12:49:32.7085172Z letter, one lowercase letter, and one number.
2021-06-28T12:49:32.7086525Z Container IP Address: 172.22.71.160
2021-06-28T12:49:32.7087093Z Container Hostname  : ci
2021-06-28T12:49:32.7087562Z Container Dns Name  : ci
2021-06-28T12:49:32.7088142Z Web Client          : http://ci/NAV/
2021-06-28T12:49:32.7088716Z Dev. Server         : http://ci
2021-06-28T12:49:32.7089329Z Dev. ServerInstance : NAV
2021-06-28T12:49:32.7089900Z Setting ci to 172.22.71.160 in host hosts file
2021-06-28T12:49:32.7090333Z 
2021-06-28T12:49:32.7090686Z Files:
2021-06-28T12:49:32.7091141Z http://ci:8080/ALLanguage.vsix
2021-06-28T12:49:32.7091536Z 
2021-06-28T12:49:32.7091977Z Container Total Physical Memory is 16.0Gb
2021-06-28T12:49:32.7092524Z Container Free Physical Memory is 10.0Gb
2021-06-28T12:49:32.7092931Z 
2021-06-28T12:49:32.7093343Z Initialization took 86 seconds
2021-06-28T12:49:32.7093807Z Ready for connections!
2021-06-28T12:49:32.7105780Z Reading CustomSettings.config from ci
2021-06-28T12:49:35.2046328Z Creating Desktop Shortcuts for ci
2021-06-28T12:49:36.1450288Z Container ci successfully created
2021-06-28T12:49:36.1453903Z 
2021-06-28T12:49:36.1474408Z Use:
2021-06-28T12:49:36.1493118Z Get-BcContainerEventLog -containerName ci to retrieve a snapshot of the event log from the container
2021-06-28T12:49:36.1509966Z Get-BcContainerDebugInfo -containerName ci to get debug information about the container
2021-06-28T12:49:36.1522442Z Enter-BcContainer -containerName ci to open a PowerShell prompt inside the container
2021-06-28T12:49:36.1535401Z Remove-BcContainer -containerName ci to remove the container again
2021-06-28T12:49:36.1548214Z docker logs ci to retrieve information about URL's again
2021-06-28T12:49:36.1556321Z DLLs found: 
2021-06-28T12:49:36.1876681Z     -FileHelper.dll
2021-06-28T12:49:36.6874380Z Copy C:\agent\_work\1\s\base\.netpackages\FileHelper.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\FileHelper.dll)
2021-06-28T12:49:38.2917829Z     -JsonHelper.dll
2021-06-28T12:49:38.5681496Z Copy C:\agent\_work\1\s\base\.netpackages\JsonHelper.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\JsonHelper.dll)
2021-06-28T12:49:39.0054757Z     -MigraDoc.DocumentObjectModel.dll
2021-06-28T12:49:39.3200770Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.DocumentObjectModel.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.DocumentObjectModel.dll)
2021-06-28T12:49:39.8374370Z     -MigraDoc.Rendering.dll
2021-06-28T12:49:40.1408861Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.Rendering.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.Rendering.dll)
2021-06-28T12:49:40.6985402Z     -MigraDoc.RtfRendering.dll
2021-06-28T12:49:40.9966534Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.RtfRendering.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.RtfRendering.dll)
2021-06-28T12:49:41.6406754Z     -PdfSharp.Charting.dll
2021-06-28T12:49:41.9517413Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\PdfSharp.Charting.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.Charting.dll)
2021-06-28T12:49:42.5889928Z     -PdfSharp.dll
2021-06-28T12:49:42.8909362Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\PdfSharp.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.dll)
2021-06-28T12:49:43.4402717Z     -MigraDoc.DocumentObjectModel.resources.dll
2021-06-28T12:49:43.7287662Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.DocumentObjectModel.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.DocumentObjectModel.resources.dll)
2021-06-28T12:49:44.0711217Z     -MigraDoc.Rendering.resources.dll
2021-06-28T12:49:44.3731507Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.Rendering.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.Rendering.resources.dll)
2021-06-28T12:49:44.7150208Z     -MigraDoc.RtfRendering.resources.dll
2021-06-28T12:49:45.0125950Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.RtfRendering.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.RtfRendering.resources.dll)
2021-06-28T12:49:45.3467996Z     -PdfSharp.Charting.resources.dll
2021-06-28T12:49:45.6479413Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\PdfSharp.Charting.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.Charting.resources.dll)
2021-06-28T12:49:45.9985792Z     -PdfSharp.resources.dll
2021-06-28T12:49:46.3400533Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\PdfSharp.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.resources.dll)
2021-06-28T12:49:46.6814786Z Importing C/AL object dependencies . . . 
2021-06-28T12:49:46.6949924Z     -BC14Changes.fob
2021-06-28T12:49:47.3944120Z Copy C:\agent\_work\1\s\.devOps\.dependencies\BC14Changes.fob to container ci (c:\run\BC14Changes.fob)
2021-06-28T12:49:47.8254376Z Importing Objects from c:\run\BC14Changes.fob (container path)
2021-06-28T12:50:06.3509527Z Objects successfully imported
2021-06-28T12:50:06.3518725Z     -BC14ChangesDataTransfer.fob
2021-06-28T12:50:07.6830795Z Copy C:\agent\_work\1\s\.devOps\.dependencies\BC14ChangesDataTransfer.fob to container ci (c:\run\BC14ChangesDataTransfer.fob)
2021-06-28T12:50:08.0373173Z Importing Objects from c:\run\BC14ChangesDataTransfer.fob (container path)
2021-06-28T12:50:30.5856852Z Objects successfully imported
2021-06-28T12:50:30.5865592Z     -BC14Partner_Atlas.fob
2021-06-28T12:50:31.2381218Z Copy C:\agent\_work\1\s\.devOps\.dependencies\BC14Partner_Atlas.fob to container ci (c:\run\BC14Partner_Atlas.fob)
2021-06-28T12:50:31.6710495Z Importing Objects from c:\run\BC14Partner_Atlas.fob (container path)
2021-06-28T12:50:32.4985460Z System.Management.Automation.RemoteException
2021-06-28T12:50:32.5002687Z at Import-NAVApplicationObject<Process>, C:\Program Files (x86)\Microsoft Dynamics NAV\140\RoleTailored Client\Microsoft.Dynamics.Nav.Ide.psm1: line 159
2021-06-28T12:50:32.5003607Z at <ScriptBlock>, <No file>: line 27
2021-06-28T12:50:32.5018786Z bei Invoke-ScriptInBcContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ContainerHandling\Invoke-ScriptInNavContainer.ps1: Zeile 44
2021-06-28T12:50:32.5023771Z bei Import-ObjectsToNavContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ObjectHandling\Import-ObjectsToNavContainer.ps1: Zeile 44
2021-06-28T12:50:32.5028120Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 75
2021-06-28T12:50:32.5032539Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 72
2021-06-28T12:50:32.5037073Z bei <ScriptBlock>, C:\agent\_work\_temp\01aca315-1cd3-40ff-b6d7-ffd05aadcab7.ps1: Zeile 2
2021-06-28T12:50:32.5041438Z bei <ScriptBlock>, <Keine Datei>: Zeile 1
2021-06-28T12:50:32.6536757Z Get-ChildItem : System.Management.Automation.RemoteException
2021-06-28T12:50:32.6537585Z In C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1:72 Zeichen:1
2021-06-28T12:50:32.6538080Z + Get-ChildItem -Path ".devOps\.dependencies" -Recurse -Filter "*.fob"  ...
2021-06-28T12:50:32.6538501Z + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2021-06-28T12:50:32.6539083Z     + CategoryInfo          : OperationStopped: (System.Manageme...RemoteException:String) [Get-ChildItem], RuntimeExc 
2021-06-28T12:50:32.6539544Z    eption
2021-06-28T12:50:32.6539991Z     + FullyQualifiedErrorId : System.Management.Automation.RemoteException,Microsoft.PowerShell.Commands.GetChildItemC 
2021-06-28T12:50:32.6540422Z    ommand
2021-06-28T12:50:32.6540622Z  
2021-06-28T12:50:32.6991381Z ##[debug]Exit code: 1
2021-06-28T12:50:32.7032058Z ##[debug]Leaving Invoke-VstsTool.
2021-06-28T12:50:32.7320498Z ##[error]PowerShell wurde beendet mit dem Code "1".
2021-06-28T12:50:32.7331057Z ##[debug]Processed: ##vso[task.logissue type=error]PowerShell wurde beendet mit dem Code "1".
2021-06-28T12:50:32.7439562Z ##[debug]Processed: ##vso[task.complete result=Failed]Error detected
2021-06-28T12:50:32.7452133Z ##[debug]Leaving C:\agent\_work\_tasks\PowerShell_e213ff0f-5d5c-4791-802d-52ea3e7be1f1\2.140.2\powershell.ps1.
2021-06-28T12:50:32.7728723Z ##[section]Async Command Start: Buildnummer aktualisieren
2021-06-28T12:50:32.7729847Z Buildnummer auf 14.24.20210628.27 für den Build 27 aktualisieren
2021-06-28T12:50:32.7730629Z ##[section]Async Command End: Buildnummer aktualisieren
2021-06-28T12:50:32.7732691Z ##[section]Abschließen: Create Container

General information

BC Version: 14.24.46857.0 de DevOps Version: Azure DevOps Server Version 17.143.28621.4

freddydk commented 3 years ago

accept_eula and accept_outdated are switches - not boolean parameters. You need to remove the $true after these.

New-BcContainer `
    -accept_eula `
    -accept_outdated `
    -artifactUrl $artifact `
    -containerName $containerName `
    -auth NavUserPassword `
    -Credential $credential `
    -includeCSide `
    -licenseFile $licenseFile.FullName `
    -memoryLimit "4G" `
    -updateHosts `
    -enableSymbolLoading `
    -useBestContainerOS
freddydk commented 3 years ago

Did this fix the issue?

sirhc101 commented 3 years ago

I will try today with the customer. Keep you informed.

Thank you so far

sirhc101 commented 3 years ago

Container creation looks good, even the image name. Thanks... but it fails in further processing anyway. I fails in using Import-ObjectsToNavContainer.

2021-07-01T09:53:11.4053974Z ##[section]Starten: Create Container
2021-07-01T09:53:11.4065154Z ==============================================================================
2021-07-01T09:53:11.4065771Z Task         : PowerShell
2021-07-01T09:53:11.4066205Z Description  : Führen Sie ein PowerShell-Skript unter Windows, macOS oder Linux aus.
2021-07-01T09:53:11.4066617Z Version      : 2.140.2
2021-07-01T09:53:11.4066941Z Author       : Microsoft Corporation
2021-07-01T09:53:11.4067390Z Help         : [Weitere Informationen](https://go.microsoft.com/fwlink/?LinkID=613736)
2021-07-01T09:53:11.4067889Z ==============================================================================
2021-07-01T09:53:12.3473460Z Skript wird erstellt.
2021-07-01T09:53:12.3556001Z Formatierter Befehl: . 'C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1'
2021-07-01T09:53:12.4124596Z ##[command]"C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command ". 'C:\agent\_work\_temp\404e4148-9f3e-497d-a1a7-c6699c0b2077.ps1'"
2021-07-01T09:53:12.7081400Z App Version: 14.24.20210701.31
2021-07-01T09:53:12.9563795Z BcContainerHelper version 2.0.14
2021-07-01T09:53:15.2993327Z Artifacts found: https://bcartifacts.azureedge.net/onprem/14.24.46857.0/de
2021-07-01T09:53:15.3795467Z License file: BC14_20210615.flf
2021-07-01T09:53:16.7541816Z BcContainerHelper is version 2.0.14
2021-07-01T09:53:16.7548193Z BcContainerHelper is running as administrator
2021-07-01T09:53:16.7569026Z Host is Microsoft Windows Server 2019 Standard - ltsc2019
2021-07-01T09:53:16.8813909Z Docker Client Version is 20.10.5
2021-07-01T09:53:16.8837445Z Docker Server Version is 20.10.5
2021-07-01T09:53:17.2488914Z Fetching all docker images
2021-07-01T09:53:17.3752925Z Fetching all docker volumes
2021-07-01T09:53:17.4849338Z ArtifactUrl and ImageName specified
2021-07-01T09:53:17.6832948Z Image 14.24.46857.0:onprem-14.24.46857.0-de already exists
2021-07-01T09:53:18.0232577Z Using image 14.24.46857.0:onprem-14.24.46857.0-de
2021-07-01T09:53:18.1832613Z Creating Container ci
2021-07-01T09:53:18.2015963Z Version: 14.24.46857.0-de
2021-07-01T09:53:18.2023104Z Style: onprem
2021-07-01T09:53:18.2029199Z Multitenant: No
2021-07-01T09:53:18.2050702Z Platform: 14.0.46844.0
2021-07-01T09:53:18.2056898Z Generic Tag: 1.0.1.7
2021-07-01T09:53:18.2084598Z Container OS Version: 10.0.17763.1935 (ltsc2019)
2021-07-01T09:53:18.2092036Z Host OS Version: 10.0.17763.1935 (ltsc2019)
2021-07-01T09:53:18.2135558Z Using process isolation
2021-07-01T09:53:18.2186821Z Using locale de-DE
2021-07-01T09:53:18.2211588Z Disabling the standard eventlog dump to container log every 2 seconds (use -dumpEventLog to enable)
2021-07-01T09:53:18.2278114Z Using license file \\xxx\BC14_20210615.flf
2021-07-01T09:53:18.2877472Z Files in C:\ProgramData\BcContainerHelper\Extensions\ci\my:
2021-07-01T09:53:18.2981886Z - AdditionalOutput.ps1
2021-07-01T09:53:18.2989283Z - AdditionalSetup.ps1
2021-07-01T09:53:18.2996314Z - license.flf
2021-07-01T09:53:18.3003160Z - MainLoop.ps1
2021-07-01T09:53:18.3009954Z - SetupVariables.ps1
2021-07-01T09:53:18.3016761Z - updatehosts.ps1
2021-07-01T09:53:18.3023425Z Creating container ci from image 14.24.46857.0:onprem-14.24.46857.0-de
2021-07-01T09:53:18.4907162Z 398aeab4532a7aff9d9cb96c6b3acd6420425dbbebdfe31c94422f5353c929da
2021-07-01T09:53:20.3116704Z Waiting for container ci to be ready
2021-07-01T09:53:22.5778172Z Initializing...
2021-07-01T09:53:22.5778927Z Setting host.containerhelper.internal to 172.22.64.1 in container hosts file
2021-07-01T09:53:22.5779424Z Starting Container
2021-07-01T09:53:22.5779674Z Hostname is ci
2021-07-01T09:53:23.7040495Z PublicDnsName is ci
2021-07-01T09:53:24.8428844Z Using NavUserPassword Authentication
2021-07-01T09:53:25.9823287Z Starting Local SQL Server
2021-07-01T09:53:27.1110094Z Starting Internet Information Server
2021-07-01T09:53:28.2384366Z Creating Self Signed Certificate
2021-07-01T09:53:28.2386771Z Self Signed Certificate Thumbprint 10017DF3B449DEB127212AFE82ADA91B6289FE13
2021-07-01T09:53:28.2387335Z Modifying Service Tier Config File with Instance Specific Settings
2021-07-01T09:54:05.1606673Z Starting Service Tier
2021-07-01T09:54:05.1607743Z Registering event sources
2021-07-01T09:54:14.5617323Z Creating DotNetCore Web Server Instance
2021-07-01T09:54:14.5619292Z Using license file 'c:\run\my\license.flf'
2021-07-01T09:54:14.5621041Z Import License
2021-07-01T09:54:14.5622911Z Creating http download site
2021-07-01T09:54:15.7205343Z Setting SA Password and enabling SA
2021-07-01T09:54:17.2459638Z Creating admin as SQL User and add to sysadmin
2021-07-01T09:54:17.2460697Z Creating SUPER user
2021-07-01T09:54:17.2461247Z WARNING: The password that you entered does not meet the minimum requirements. 
2021-07-01T09:54:17.2461851Z It should be at least 8 characters long and contain at least one uppercase 
2021-07-01T09:54:44.0872234Z letter, one lowercase letter, and one number.
2021-07-01T09:54:44.0873043Z Container IP Address: 172.22.64.255
2021-07-01T09:54:44.0873399Z Container Hostname  : ci
2021-07-01T09:54:44.0873700Z Container Dns Name  : ci
2021-07-01T09:54:44.0874042Z Web Client          : http://ci/NAV/
2021-07-01T09:54:44.0874383Z Dev. Server         : http://ci
2021-07-01T09:54:44.0874693Z Dev. ServerInstance : NAV
2021-07-01T09:54:44.0875049Z Setting ci to 172.22.64.255 in host hosts file
2021-07-01T09:54:44.0875314Z 
2021-07-01T09:54:44.0875519Z Files:
2021-07-01T09:54:44.0875830Z http://ci:8080/ALLanguage.vsix
2021-07-01T09:54:44.0876075Z 
2021-07-01T09:54:44.0876350Z Container Total Physical Memory is 16.0Gb
2021-07-01T09:54:44.0876695Z Container Free Physical Memory is 10.3Gb
2021-07-01T09:54:44.0876939Z 
2021-07-01T09:54:44.0877199Z Initialization took 81 seconds
2021-07-01T09:54:44.0877488Z Ready for connections!
2021-07-01T09:54:44.0892736Z Reading CustomSettings.config from ci
2021-07-01T09:54:46.3130068Z Creating Desktop Shortcuts for ci
2021-07-01T09:54:47.5894667Z Container ci successfully created
2021-07-01T09:54:47.5897248Z 
2021-07-01T09:54:47.5903513Z Use:
2021-07-01T09:54:47.5916598Z Get-BcContainerEventLog -containerName ci to retrieve a snapshot of the event log from the container
2021-07-01T09:54:47.5928297Z Get-BcContainerDebugInfo -containerName ci to get debug information about the container
2021-07-01T09:54:47.5940112Z Enter-BcContainer -containerName ci to open a PowerShell prompt inside the container
2021-07-01T09:54:47.5951997Z Remove-BcContainer -containerName ci to remove the container again
2021-07-01T09:54:47.5964046Z docker logs ci to retrieve information about URL's again
2021-07-01T09:54:47.5969922Z DLLs found: 
2021-07-01T09:54:47.6226949Z     -FileHelper.dll
2021-07-01T09:54:48.6654406Z Copy C:\agent\_work\1\s\Base\.netpackages\FileHelper.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\FileHelper.dll)
2021-07-01T09:54:49.0697856Z     -JsonHelper.dll
2021-07-01T09:54:49.3592859Z Copy C:\agent\_work\1\s\Base\.netpackages\JsonHelper.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\JsonHelper.dll)
2021-07-01T09:54:49.7471232Z     -MigraDoc.DocumentObjectModel.dll
2021-07-01T09:54:50.0606638Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.DocumentObjectModel.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.DocumentObjectModel.dll)
2021-07-01T09:54:50.9805161Z     -MigraDoc.Rendering.dll
2021-07-01T09:54:52.0686794Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.Rendering.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.Rendering.dll)
2021-07-01T09:54:52.6037816Z     -MigraDoc.RtfRendering.dll
2021-07-01T09:54:52.9047220Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\MigraDoc.RtfRendering.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.RtfRendering.dll)
2021-07-01T09:54:53.5161713Z     -PdfSharp.Charting.dll
2021-07-01T09:54:53.8108604Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\PdfSharp.Charting.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.Charting.dll)
2021-07-01T09:54:54.2745476Z     -PdfSharp.dll
2021-07-01T09:54:54.5797180Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\PdfSharp.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.dll)
2021-07-01T09:54:55.1072033Z     -MigraDoc.DocumentObjectModel.resources.dll
2021-07-01T09:54:55.4251352Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.DocumentObjectModel.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.DocumentObjectModel.resources.dll)
2021-07-01T09:54:55.8155217Z     -MigraDoc.Rendering.resources.dll
2021-07-01T09:54:56.1354665Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.Rendering.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.Rendering.resources.dll)
2021-07-01T09:54:56.4666812Z     -MigraDoc.RtfRendering.resources.dll
2021-07-01T09:54:56.7764696Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\MigraDoc.RtfRendering.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\MigraDoc.RtfRendering.resources.dll)
2021-07-01T09:54:57.1149713Z     -PdfSharp.Charting.resources.dll
2021-07-01T09:54:57.4239859Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\PdfSharp.Charting.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.Charting.resources.dll)
2021-07-01T09:54:57.7706356Z     -PdfSharp.resources.dll
2021-07-01T09:54:58.0905129Z Copy C:\agent\_work\1\s\Verkauf\.netpackages\PDFsharp\de\PdfSharp.resources.dll to container ci (C:\Program Files\Microsoft Dynamics NAV\140\Service\Add-Ins\PdfSharp.resources.dll)
2021-07-01T09:54:58.4514060Z Importing C/AL object dependencies . . . 
2021-07-01T09:54:58.4625326Z     -BC14Changes.fob
2021-07-01T09:54:59.1876258Z Copy C:\agent\_work\1\s\.devOps\.dependencies\BC14Changes.fob to container ci (c:\run\BC14Changes.fob)
2021-07-01T09:54:59.6206691Z Importing Objects from c:\run\BC14Changes.fob (container path)
2021-07-01T09:55:02.1089352Z Vom Hintergrundvorgang wurde ein Fehler mit der folgenden Meldung ausgegeben: "Der Named Pipe-Zielprozess wurde beendet.".
2021-07-01T09:55:02.1116873Z bei Invoke-ScriptInBcContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ContainerHandling\Invoke-ScriptInNavContainer.ps1: Zeile 39
2021-07-01T09:55:02.1118489Z bei Import-ObjectsToNavContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ObjectHandling\Import-ObjectsToNavContainer.ps1: Zeile 44
2021-07-01T09:55:02.1119576Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 73
2021-07-01T09:55:02.1120356Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 70
2021-07-01T09:55:02.1121029Z bei <ScriptBlock>, C:\agent\_work\_temp\404e4148-9f3e-497d-a1a7-c6699c0b2077.ps1: Zeile 2
2021-07-01T09:55:02.1121518Z bei <ScriptBlock>, <Keine Datei>: Zeile 1
2021-07-01T09:55:02.1137472Z bei Invoke-ScriptInBcContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ContainerHandling\Invoke-ScriptInNavContainer.ps1: Zeile 44
2021-07-01T09:55:02.1143141Z bei Import-ObjectsToNavContainer, C:\Program Files\WindowsPowerShell\Modules\BcContainerHelper\2.0.14\ObjectHandling\Import-ObjectsToNavContainer.ps1: Zeile 44
2021-07-01T09:55:02.1151046Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 73
2021-07-01T09:55:02.1157038Z bei <ScriptBlock>, C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1: Zeile 70
2021-07-01T09:55:02.1161411Z bei <ScriptBlock>, C:\agent\_work\_temp\404e4148-9f3e-497d-a1a7-c6699c0b2077.ps1: Zeile 2
2021-07-01T09:55:02.1168287Z bei <ScriptBlock>, <Keine Datei>: Zeile 1
2021-07-01T09:55:02.2773106Z Get-ChildItem : Vom Hintergrundvorgang wurde ein Fehler mit der folgenden Meldung ausgegeben: "Der Named Pipe-Zielprozess wurde beendet.".
2021-07-01T09:55:02.2774852Z In C:\agent\_work\1\s\.devOps\scripts\Create-Container.ps1:70 Zeichen:1
2021-07-01T09:55:02.2775519Z + Get-ChildItem -Path ".devOps\.dependencies" -Recurse -Filter "*.fob"  ...
2021-07-01T09:55:02.2776148Z + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2021-07-01T09:55:02.2776936Z     + CategoryInfo          : OperationStopped: (Vom Hintergrund...urde beendet.".:String) [Get-ChildItem], RuntimeExc 
2021-07-01T09:55:02.2777651Z    eption
2021-07-01T09:55:02.2778430Z     + FullyQualifiedErrorId : Vom Hintergrundvorgang wurde ein Fehler mit der folgenden Meldung ausgegeben: "Der Named 
2021-07-01T09:55:02.2779340Z     Pipe-Zielprozess wurde beendet.".,Microsoft.PowerShell.Commands.GetChildItemCommand
2021-07-01T09:55:02.2779826Z  
2021-07-01T09:55:02.3859371Z ##[error]PowerShell wurde beendet mit dem Code "1".
2021-07-01T09:55:02.4250562Z ##[section]Async Command Start: Buildnummer aktualisieren
2021-07-01T09:55:02.4251379Z Buildnummer auf 14.24.20210701.31 für den Build 31 aktualisieren
2021-07-01T09:55:02.4251880Z ##[section]Async Command End: Buildnummer aktualisieren
2021-07-01T09:55:02.4253358Z ##[section]Abschließen: Create Container
freddydk commented 3 years ago

When copying files into a container, some times it takes some time before the file is accessible. If you add ".devOps.dependencies" as a share to the container, then it doesn't need to do the copy - it will just take it from the folder. -additionalparameters @("--volume ""C:\agent\_work\1\s\.devOps\.dependencies:c:\dependencies""") should do the trick

freddydk commented 3 years ago

did this do the trick?

sirhc101 commented 3 years ago

I think it did, but we're still struggling with similar error messages while importing fob files into the container.

Right now I cannot describe it, because if we run the same pipeline 10 times it happens approx. only 7 times.

I currently do try all steps manually to find out what's wrong and will come back here, after it's a little more clear.

Thanks so far

sirhc101 commented 3 years ago

It looks like a combination of volume mapping, as you suggested and memory limit. After adding the volumes ("s"(ources) directory and "a"(rtifacts) directory from agent work folder) it failed only sometimes. After a lot of testing, I set the container memory limit from 4GB to 8GB and now it seems to work everytime.

Thank you very much. Case closed :-)