When using VSCode extension it automatically creates the appsettings.json file in the project root but the Azure DevOps task expects the appsettings.json file to be in the policies folder otherwise it fails with the following error:
##[error]Unhandled: ENOENT: no such file or directory, open '/home/vsts/work/1/s/policies/appsettings.json'
It would be good if this feature was supported so we can get the best developer experience.
Current workaround
Add one additional step to the pipeline to copy appsettings.json inside the policies folder.