I have a Function App and deployed functions using Visual Studio, so it became read only and unable to add proxies to read only function app. How can I add proxies to my Function App from Visual Studio?
Proxies.json is defined by a proxies object, which is composed of named proxies and their definitions. Optionally, if your editor supports it, you can reference a JSON schema for code completion. An example file might look like the following: JSON Copy.
AzureWebJobsStorage. The Azure Functions runtime uses this storage account connection string for normal operation. Some uses of this storage account include key management, timer trigger management, and Event Hubs checkpoints. The storage account must be a general-purpose one that supports blobs, queues, and tables.
In the Add a new API list, select Function App. Click Browse to select Functions for import. Click on the Function App section to choose from the list of available Function Apps. Find the Function App you want to import Functions from, click on it and press Select.
I had this exact problem but when I added the proxies.json file to the project, it would never be published. I discovered that I had to edit the project's csproj file and find the proxies.json file XML element:
<None Update="proxies.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToPublishDirectory>Never</CopyToPublishDirectory>
</None>
and change CopyToPublishDirectory
to PreserveNewest
with: <CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
.
Add your proxies.json file in the root of your Visual Studio project and make sure to mark it as "include in output".
Alternatively, you can go to Function App Settings and toggle "read only" to "read/write" to allow the portal to be editable again. Just beware, your proxies.json file might get deleted when you deploy from VS again (if you select "remove files at destination" when you publish). Be sure you add it to your VS project.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With