Join Slack
Powered by
<#17828 Azure Function Support> New discussion cre...
# github-notifications
q
quaint-telephone-89068
12/16/2022, 8:23 PM
#17828 Azure Function Support
New discussion created by
calleo
Hi, I am very new to Pants, but I am trying to consolidate a number of repositories of Azure Functions into a single one and use Pants to have a consistent development workflow and package them up before they are deployed. Azure functions can be deployed in a number of ways using the Azure CLI, but I believe using the "zip deploy" method would suit Pants the best. In short, any local Python files and config-files (json) are added to the zip and all 3rd part dependencies are installed into a sub-directory. It's a lot like the pex-files, but folder structure is different. Azure docs:
https://learn.microsoft.com/en-us/azure/azure-functions/functions-reference-python?tabs=asgi%2Capplication-level&pivots=python-mode-configuration#install-local-packages
Another alternative would be to replicate this folder structure (see link below) in the dist folder and let Azure install dependencies from a requirements-file:
https://learn.microsoft.com/en-us/azure/azure-functions/functions-reference-python?tabs=asgi%2Capplication-level&pivots=python-mode-decorators#folder-structure
Then deploy from that folder using the Azure CLI. Perhaps it's possible to combine existing Pants-functionality to build such an archive?
pantsbuild/pants
Open in Slack
Previous
Next