Extending existing resource with custom fields
See original GitHub issueI’ve looked at Convert from JSON to an F# anonymous record and Migrating to IArmResource, and (correct me if I am wrong) it looks like it does not allow adding fields/properties to existing resources (but rather only creating new resources from scratch). Is there a way to just add custom JSON or anonymous record to e.g. a webApp
?
More specifically I am looking to mount Azure Storage as a local share in a container app in App Service by adding the following under “properties” (next to e.g. siteConfig
that is already generated by Farmer):
"azureStorageAccounts": {
"my-storage-mount": {
"type": "AzureFiles",
"accountName": "storageAccountName",
"shareName": "sharename",
"mountPath": "/data",
"accessKey": "..."
}
}
Would I have to recreate the whole webApp
or Microsoft.Web/sites/config
JSON manually in order to add this section, or is there a way to just “jack in” a custom field for azureStorageAccounts
?
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Using Custom Fields to find Available Resources based ...
Add your own Custom Fields to your Resources and Projects to Quickly Match and Find Available Resources against your Project Requirements.
Read more >Extending the profile resource with a new field
Choose the Extend an existing resource option. Select the Profile (profile) resource. Click Create. In the Fields category of the Data ...
Read more >Extend the Kubernetes API with CustomResourceDefinitions
This page shows how to install a custom resource into the Kubernetes API by creating a CustomResourceDefinition. Before you begin You need ...
Read more >Custom Structures - HAPI FHIR Documentation
The most elegant way of adding extensions to a resource is through the use of custom fields. The following example shows a custom...
Read more >Add custom data to resources using extensions
In this article, we'll discuss how Microsoft Graph supports extending its resources, the options available to add custom properties and when to ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@Yakimych exactly right. We’d have to have some way of splicing the JSON together. A crude option would be that we give you access to the final JSON as a JObject (or whatever the System Text JSON equivalent of that is) and it’s your responsibility to return back some valid JSON.
@Yakimych great question. For the moment, it’s unfortunately the former - you can only add in entirely new resources, rather than modifying an object. I’ve been thinking about ways of letting you “plug in” to the very bottom of the pipeline though to modify the JSON that is output as well, but unfortunately nothing that’s ready for testing out.