2

I am using the provided ARM Templates to deploy a Sitecore 9.3 XP Scaled topology to Azure PaaS, and then planning to add some adjustments. It all went mostly fine, but I'm stuck now when I tried to add SXA+PS as a module. Following the documentation, I added this snippet to the azuredeploy.parameters.json file:

"modules": {
  "value": {
    "items": [
      {
        "name": "sxa",
        "templateLink": "",
        "parameters": {
          "cdSxaMsDeployPackageUrl": "",
          "cmSxaMsDeployPackageUrl": "",
          "speMsDeployPackageUrl": ""
        }
      },
      {
        "name": "bootloader",
        "templateLink": "",
        "parameters": {
          "msDeployPackageUrl": ""
        }
      }
    ]
  }
}

and populated with the right values. I do have the right templates and scwdp packages uploaded to my blob storage, just the same as the other templates and packages that are actually working.

However, once I add the "modules", I am getting this error from the azuredeploy.json template, which is not a valid template anymore:

New-AzResourceGroupDeployment : 12:13:25 - Error: Code=InvalidTemplate; Message=Deployment template validation failed: 'The template variable 'dependencies' is not valid: The language expression property 'items' doesn't exist, available properties are 'CliXml'.. Please see https://aka.ms/arm-template-expressions for usage details.'.

Which is referring to this variable in the main template:

"dependencies": "[concat(variables('defaultDependency'), parameters('modules').items)]"

which I haven't changed, and seems to be just like that from the previous versions. Nothing came up from googling this. Any idea what am I doing wrong? Many thanks in advance.

1
  • Did you solve this issue? Any news on it? Commented Feb 14, 2023 at 10:17

1 Answer 1

0

You can add this to the parameter section of your azuredeploy.json ARM template instead of your azuredeploy.parameters.json parameter file.

So the azuredeploy.json will look something like this (this snippet assumes you have uploaded your Sitecore WDPs to a blob storage and is only an example for the JSS module. The bootloader is always required)

"parameters": {
"modules": {
  "type": "secureObject",
  "defaultValue": {
    "items": [
      {
        "name": "empty",
        "templateLink": "[concat(uri(parameters('templateLinkBase'), 'nested/emptyAddon.json'), parameters('templateLinkAccessToken'))]",
        "parameters": {
        }
      },
       {
      "name": "bootloader",
      "templateLink": "https://raw.githubusercontent.com/Sitecore/Sitecore-Azure-Quickstart-Templates/master/Sitecore%2010.2.0/XM/addons/bootloader.json",
      "parameters": {
        "msDeployPackageUrl" : "https://xxxxxxxxxx.blob.core.windows.net/sitecorepwd/Sitecore.Cloud.Integration.Bootload.wdp.zip"
      }
    },
    {
      "name": "jss",
      "templateLink": "https://raw.githubusercontent.com/Sitecore/Sitecore-Azure-Quickstart-Templates/master/JSS%2019.0.0/xm/azuredeploy.json",
      "parameters":
      {
        "jssMsDeployPackageUrl": "https://xxxxxxxxxx.blob.core.windows.net/sitecorepwd/Sitecore Headless Services Server XM 21.0.583.scwdp.zip",
        "jssCDMsDeployPackageUrl": "https://xxxxxxxxxxx.blob.core.windows.net/sitecorepwd/Sitecore Headless Services Server XM CD 21.0.583.scwdp.zip"
      }
    }

Hope it works for you as well!

1
  • As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
    – Community Bot
    Commented Feb 27, 2023 at 14:06

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.