Working on Azure Pipeline as code and trying to create a resource via ARM template in Azure using YAML pipeline.
In Azure DevOps, I have pushed the code (deployment json, parameter json and yml file etc) into Azure Repos Git under a feature branch.
While running the pipeline, I am facing the error "Error: Could not find any file matching the template file pattern" due to "csmFile" value.
my yml file contains ARM template deployment info as below.
trigger:
branches:
include:
- dev-pipecode
pool:
vmImage: 'windows-latest'
steps:
- task: AzureResourceManagerTemplateDeployment@3
inputs:
deploymentScope: 'Resource Group'
azureResourceManagerConnection: 'company-development-Contributor'
subscriptionId: 'XXXXXXXX'
action: 'Create Or Update Resource Group'
resourceGroupName: 'name of the resource group'
location: 'North Europe'
templateLocation: 'Linked artifact'
csmFile: '$(System.DefaultWorkingDirectory)/AzureAuto/pipelineascode.json'
csmParametersFile: '$(System.DefaultWorkingDirectory)/AzureAuto/param-pipelineascode.json'
deploymentMode: 'Incremental'
Am I missing something? Please guide me. Thanks.