I was able to get this working. In order to use a keyvault for the backend root certificate:
- Put the public key in a keyvault as the value of a Secret (not a Certificate). No header, footer, or line breaks.
- In your App Gateway template, insert a trustedRootCertificates block, and in Properties, use the keyVaultSecretId key. Its value will be the full path to the secret (https://<keyvaulturl>/secrets/<secretname>)
- Reference the above in the backendHTTPSettingsCollection portion of the App Gateway.