question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The template reference 'myAppInsights' is not valid

See original GitHub issue

Hello! 👋🏻

I’m going through some trouble trying to deploy an Azure Function and was hoping you’d have any insights. My issue is actually related to the link_to_service_plan and link_to_app_insights settings. Turns out I’m trying to link to a service plan and an app insights instance that are located in different resource groups, and I keep getting this error: Deployment template validation failed: 'The template reference 'myAppInsights' is not valid: could not find template resource or resource copy with this name.

I did some digging and, apparently, I have to reference resources located in different resource groups using the resourceId arm function so it takes a resource group name and is properly able to resolve the reference. I couldn’t find a way to make this work from Farmer, though =(

Any ideas how I could make this work?

Thanks!

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
isaacabrahamcommented, Aug 12, 2020

Now pushed to NuGet 😃

0reactions
VitorRigonicommented, Aug 12, 2020

That’s perfect!

I actually went through the discussion and saw the references to link_to_unmanaged_service_plan already merged to master, but there was no new release yet so I was just anxiously waiting for the new version to be able to use that 😁 And meanwhile I can work around with that other way that works fine for me (even though it’s pushing the farmer api limits a little bit 😅)

Read more comments on GitHub >

github_iconTop Results From Across the Web

The template reference 'not valid error in arm template
I have to deploy/crease resource group if not exist in azure portal using arm template. arm template should be called through uri in...
Read more >
The template deployment is not valid according to ...
What happened: The template deployment 'dev-acs' is not valid according to the validation procedure. The tracking id is 'xxxxxxx-xxxx-xxxx ...
Read more >
Invalid template errors - Azure Resource Manager
This article describes how to resolve invalid template errors for Bicep files and Azure Resource Manager templates (ARM templates).
Read more >
ARM template, "reference not found" on resource that exists
... error "The template reference 'ins-test-api-centralus' is not valid: could not find template resource or resource copy with this name.
Read more >
Error & Fix: ARM Linked Template 'Invalid Template .. could ...
The error is correct in stating 'The template reference 'rkfunctionapp-keyvault' is not valid: could not find template resource or resource copy ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found