1

I am trying to install Sitecore Demo site (https://github.com/Sitecore/Sitecore.Demo.Platform) on my local using the steps mentioned in this guide - https://buoctrenmay.com/2020/11/06/sitecore-xp-10-0-and-sxa-10-0-demo-lighthouse-setup-guide/

I am getting below error - 

Preparing to run build script...
Running build script...

Error: Unknown command 'DockerBuild'.



     build.cake -deploymentTarget=DockerBuild --Target Content-Management
                                    ^^^^^^^^^^^ No such command

The command 'powershell -Command $ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue'; .\build.ps1 -DeploymentTarget DockerBuild --Target Content-Management' returned a non-zero code: 1

ERROR: Service 'solution' failed to build : Build failed

Can anybody please suggest how to resolve this one? I am new to docker.

enter image description here

3
  • I assume that you have all the prerequisites, docker and environment preparations? Do you also have the 10.0 repo cloned correctly? Commented May 11, 2021 at 11:21
  • yes @CristiVulturar
    – NewbieHere
    Commented May 27, 2021 at 8:34
  • I got same error as "Error: Unknown command 'Content-Management'.
    – venkat
    Commented Jul 6, 2021 at 9:04

2 Answers 2

0

A shot in the dark...

Please review Dockerfile located here:

\docker\images\windows\demo-solution\Dockerfile

Look for line:

RUN .\build.ps1 -DeploymentTarget DockerBuild -Target Content-Management

From your error message, it looks like an additional '-' has been added to create --Target. Could you have accidentally added that? as it could potentially cause an issue.

One other thing, looks like the build.cake file is expecting argument starting with capital -DeploymentTarget. Whereas the build.ps1 file is passing it in as -deploymentTarget. Obviously this is a Sitecore repo... so very unlikely thats the issue, just a thought though...

Maybe look for line:

if ($DeploymentTarget) {$cakeArguments += "-deploymentTarget=$DeploymentTarget" }

and update to:

if ($DeploymentTarget) {$cakeArguments += "-DeploymentTarget=$DeploymentTarget" }
0

I Had this similar kind of issue and I installed the required .NET core SDK, for building it needs .NET core CLI.

Hope this works for you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.