Use an ARM template object as a parameter containing a key vault reference
I am attempting to make a generic ARM Template for deploying a VM, that will accept an object parameter that will be passed to a custom script extension and mapped into environment variables on the deployed machine. I want to avoid naming specific variables to maximise re-use. I would also like to be able to use key vault secrets in some cases.
How can I add a virtual network rule from a different ARM template?
I have an Azure ARM template that deploys (amongst other things) a storage account.