0

How to use azure functions to do import and export of database oprations on a azure postgres?

I have azure postgres flexible server VM and having private vnet for it instead of public endpoint.

Same vnet I have aks cluster and it can access the postgres database.

Can I create any azure function to do that export and import or any sql commands to run on postgres flexible private database?

I tried creating azure function app and created private endpoint in the inbound section to that vnet and postgres subnet. But it is not able to do that communication.

Please suggest.

1 Answer 1

0

To be able to access resource on your vNet, in this case the Postgres private endpoint, you need to use vNet integration with the function, not inbound private endpoints. Inbound PE will deal with connecting to the function over the vNet, not going from the function to Postgres.

You will need to use vNet Integration to join the function to the vNet, so that it can then talk to the Private Endpoint. This will require you to use either the App Service Plan or Premium version of functions, as the consumption plan does not support this.

2
  • I am getting delegation error when trying to integrate postgres network subnet with azure app as postgres subnet already delegated to postgres service
    – sardar
    Oct 3 at 14:13
  • You would need to use a separate subnet for the app service vnet integration
    – Sam Cogan
    yesterday

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .