2

So I'm trying to follow the Sitecore 10 walkthrough using the getting started template: https://doc.sitecore.com/developers/100/developer-tools/en/walkthrough--using-the-getting-started-template.html

Unfortunately I originally ran into issue because Docker for Windows was storing massive amount of data on c:\ by default and I needed to point it to a larger data drive. So I figured that out by setting the datadir in the daemon.json file.

Then I was running up.ps1 happily until I got a blue screen of death.

After rebooting and re-running up.ps1 I am seeing this error about missing parent.

Step 5/7 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Using cache
 ---> f468ae9e8b9a
Step 6/7 : COPY --from=headless_services C:\module\db C:\jss_data
ERROR: Service 'mssql' failed to build: COPY failed: failed to create rwlayer: Cannot create layer with missing parent 84cd4c7af34018487eb69e79089bc2f676fc86c04637607e8ee71a6d6f82b522: CreateFile F:\Programs\Docker\windowsfilter\84cd4c7af34018487eb69e79089bc2f676fc86c04637607e8ee71a6d6f82b522: The system cannot find the file specified.
F:\Libraries\Documents\Sitecore\sandbox\MyProject\up.ps1 : Container build failed, see errors above.
At line:1 char:1
+ .\up.ps1 -verbose
+ ~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,up.ps1

I'm pretty sure prior to the blue screen of death it had a larger number of steps but maybe I'm mistaken. Anyone know what I need to do to get past this error.

OK digging into the script I thought I'd try running docker-compose build which is where I was seeing 19 steps. I end with this error:

enter image description here

If I then try to go back to running up.ps1 I get the error above.

Edit: I think I got the blue screen of death when it was building the renderings - but I've consistently had it crash my computer twice now. Either during or at the end of Step 15.

I've tried jumping into visual studio to build it from there which worked ok after I added a global.json file with a targetted .net core 3.1 version, however I don't know what to do next to be able to run it in a container.

Update: I ran the prune command and noticed it updated the .net sdk and framework. I then went and run the up.ps1 script. Once again blue screen of death. After restart came back in and ran the command again and it starting at the Building solr part of the script. It has downloaded the images and is now extracting so will see if I get further this time.

enter image description here

Update: It got beyond the mssql section and on step 7 of something I got another blue screen of death.

Update: Ok another blue screen of death on build/publishing something. Now on re-running script I get this new error:

enter image description here

I tried changing line 28 of the dockerfile to be detailed instead of quiet in case it was failing silently but seemed to be happy at that point. But after outputting the number of packages installed another blue screen of death.

My windows is up to date and I'm running powershell as administrator so I'm not sure why it's bombing out so much.

Update: So I came across this closed issue regarding isolation level issues. https://github.com/Sitecore/docker-images/issues/244 I tried updating solr to hyperv but again blue screen of death. I then tried adding hyperv in a few more places (traefik, mssql, solr) and now I'm just back to container build failed (as pictured above):

PS F:\Libraries\Documents\Sitecore\sandbox\MyProject> .\up.ps1 -verbose
Building containers...
traefik uses an image, skipping
Building mssql
Step 1/7 : ARG PARENT_IMAGE
Step 2/7 : ARG HEADLESS_SERVICES_IMAGE
Step 3/7 : FROM ${HEADLESS_SERVICES_IMAGE} AS headless_services
 ---> d63bb73bbba5

Step 4/7 : FROM ${PARENT_IMAGE}
 ---> 06fd7aacc8a6
Step 5/7 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Using cache
 ---> 360037da7bbb
Step 6/7 : COPY --from=headless_services C:\module\db C:\jss_data
 ---> Using cache
 ---> 960506b2c434
Step 7/7 : RUN C:\DeployDatabases.ps1 -ResourcesDirectory C:\jss_data;     Remove-Item -Path C:\jss_data -Recurse -Force;
 ---> Using cache
 ---> 34b6ab2eac63

Successfully built 34b6ab2eac63
Successfully tagged myproject-xp0-mssql:latest
Building id
Step 1/2 : ARG PARENT_IMAGE
Step 2/2 : FROM ${PARENT_IMAGE}
 ---> 5a3e9bae10b5

Successfully built 5a3e9bae10b5
Successfully tagged myproject-id:latest
Building dotnetsdk
Step 1/8 : FROM mcr.microsoft.com/dotnet/core/sdk:3.1 as netcore-sdk
 ---> 50a6ccdd0e5e

Step 2/8 : FROM mcr.microsoft.com/dotnet/framework/sdk:4.8
 ---> 5124394abc64
Step 3/8 : ENV NUGET_VERSION 5.6.0
 ---> Using cache
 ---> 6d4b59840154
Step 4/8 : RUN Invoke-WebRequest "https://dist.nuget.org/win-x86-commandline/v$env:NUGET_VERSION/nuget.exe" -UseBasicParsing -OutFile "$env:ProgramFiles\NuGet\nuget.exe"
 ---> Using cache
 ---> 125cb2d5709e
Step 5/8 : COPY --from=netcore-sdk ["/Program Files/dotnet/", "/Program Files/dotnet/"]
 ---> Using cache
 ---> 1e5f11e53426
Step 6/8 : ENV     DOTNET_RUNNING_IN_CONTAINER=true     DOTNET_USE_POLLING_FILE_WATCHER=true     NUGET_XMLDOC_MODE=skip
 ---> Using cache
 ---> f5d76c435e6c
Step 7/8 : RUN $path = ${Env:PATH} + ';C:\Program Files\dotnet\;';     setx /M PATH $path
 ---> Using cache
 ---> dc7febc94316
Step 8/8 : RUN dotnet help | out-null
 ---> Using cache
 ---> 947aa228ea10

Successfully built 947aa228ea10
Successfully tagged myproject-dotnetsdk:latest
Building solution
Step 1/19 : ARG BUILD_IMAGE
Step 2/19 : FROM ${BUILD_IMAGE} AS nuget-prep
 ---> 947aa228ea10
Step 3/19 : COPY *.sln nuget.config /nuget/
 ---> Using cache
 ---> f74de7c6b088
Step 4/19 : COPY src/ /temp/
 ---> Using cache
 ---> 2ea835aec30f
Step 5/19 : RUN Invoke-Expression 'robocopy C:/temp C:/nuget/src /s /ndl /njh /njs *.csproj *.scproj packages.config'
 ---> Using cache
 ---> f3569a3e7d04

Step 6/19 : FROM ${BUILD_IMAGE} AS builder
 ---> 947aa228ea10
Step 7/19 : ARG BUILD_CONFIGURATION
 ---> Using cache
 ---> 861c069cbac6
Step 8/19 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Using cache
 ---> 2d2cd552f4c5
Step 9/19 : WORKDIR /build
 ---> Using cache
 ---> 1324ff79b6d6
Step 10/19 : COPY --from=nuget-prep ./nuget ./
 ---> Using cache
 ---> 151631b0aa4e
Step 11/19 : RUN nuget restore -Verbosity detailed
 ---> Using cache
 ---> 52574e2c432f
Step 12/19 : COPY src/ ./src/
 ---> Using cache
 ---> 460f16209f0f
Step 13/19 : RUN msbuild .\src\platform\Platform.csproj /p:Configuration=$env:BUILD_CONFIGURATION /m /p:DeployOnBuild=true /p:PublishProfile=Local
 ---> Using cache
 ---> a225be5d9bf2
Step 14/19 : WORKDIR /build/src/rendering
 ---> Using cache
 ---> f5a371ecd58e
Step 15/19 : RUN dotnet publish -c $env:BUILD_CONFIGURATION -o /build/rendering --no-restore
 ---> Using cache
 ---> ccb894bb90d3

Step 16/19 : FROM mcr.microsoft.com/windows/nanoserver:1809
 ---> 84fef6bdcd11
Step 17/19 : WORKDIR /artifacts
 ---> Using cache
 ---> c59713d9237a
Step 18/19 : COPY --from=builder /build/docker/deploy/platform  ./sitecore/
 ---> Using cache
 ---> f1e31f722f1f
Step 19/19 : COPY --from=builder /build/rendering ./rendering/
 ---> Using cache
 ---> c5fa515b4695

Successfully built c5fa515b4695
Successfully tagged myproject-solution:latest
Building solr
Step 1/2 : ARG PARENT_IMAGE
Step 2/2 : FROM ${PARENT_IMAGE}
 ---> 763d7bfb3fc0

Successfully built 763d7bfb3fc0
Successfully tagged myproject-xp0-solr:latest
Building xconnect
Step 1/2 : ARG PARENT_IMAGE
Step 2/2 : FROM ${PARENT_IMAGE}
 ---> a58b3181b284

Successfully built a58b3181b284
Successfully tagged myproject-xp0-xconnect:latest
Building xdbautomationworker
Step 1/2 : ARG PARENT_IMAGE
Step 2/2 : FROM ${PARENT_IMAGE}
 ---> 46b5a80df3f8

Successfully built 46b5a80df3f8
Successfully tagged myproject-xp0-xdbautomationworker:latest
Building cm
Step 1/18 : ARG PARENT_IMAGE
Step 2/18 : ARG SOLUTION_IMAGE
Step 3/18 : ARG TOOLS_IMAGE
Step 4/18 : ARG MANAGEMENT_SERVICES_IMAGE
Step 5/18 : ARG HEADLESS_SERVICES_IMAGE
Step 6/18 : FROM ${SOLUTION_IMAGE} as solution
 ---> c5fa515b4695

Step 7/18 : FROM ${TOOLS_IMAGE} as tools
 ---> 089849b3d870

Step 8/18 : FROM ${MANAGEMENT_SERVICES_IMAGE} AS management_services
 ---> 96423725498a

Step 9/18 : FROM ${HEADLESS_SERVICES_IMAGE} AS headless_services
 ---> d63bb73bbba5

Step 10/18 : FROM ${PARENT_IMAGE}
 ---> 84e253eaf761
Step 11/18 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Using cache
 ---> c8e4bf164749
Step 12/18 : WORKDIR C:\inetpub\wwwroot
 ---> Using cache
 ---> 2bea88873478
Step 13/18 : COPY --from=tools C:\tools C:\tools
 ---> Using cache
 ---> 0a672c057c01
Step 14/18 : COPY --from=management_services C:\module\cm\content C:\inetpub\wwwroot
 ---> Using cache
 ---> b50f056040d8
Step 15/18 : COPY --from=headless_services C:\module\cm\content C:\inetpub\wwwroot
ERROR: Service 'cm' failed to build: failed to create rwlayer: Failed to unmarshall layerchain json - invalid character '\x00' looking for beginning of value
F:\Libraries\Documents\Sitecore\sandbox\MyProject\up.ps1 : Container build failed, see errors above.
At line:1 char:1
+ .\up.ps1 -verbose
+ ~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,up.ps1
3
  • 1
    After you moved to F:\, did you relocate your existing Docker files over from C:\? – Mark Cassidy Aug 7 '20 at 10:09
  • 1
    You might attempt a docker system prune -a to start with a fresh image download. – nickwesselman Aug 7 '20 at 15:43
  • @MarkCassidy restarting the service creates a bunch of folders and files that docker uses - and I thought the up.ps1 command is responsible for downloading the required docker images. I will try pruning and kicking off the up.ps1 command again. Unfortunately new to docker and not quite sure how the bits all hang together when errors pop up. – Jen Aug 10 '20 at 0:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.