Have `az functionapp deployment` check permissions before deploying zip file
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 3.5k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 60
Description
**Related command**
`az functionapp deployment`
**Is your feature request related to a problem? Please describe.**
When deploying a function app, we expect to have specific permissions for some files. Customers are facing inconsistences when using `[func azure functionapp publish](https://learn.microsoft.com/en-us/azure/azure-functions/functions-core-tools-reference?tabs=v2#func-azure-functionapp-publish)`, which is the core tools command which zips up the function app and deploys it, versus using `az functionapp deployment`.
[These ](https://github.com/Azure/azure-functions-core-tools/blob/92f186ce0043ba459b2ff9f1413e9131e2f47301/src/Cli/func/Helpers/ZipHelper.cs#L15) are the checks that we perform on the core-tools side (give all files "666" r/w permissions unless it's a custom handler and we know the exe path then we give it a "777" r/w/x permission's).
**Describe the solution you'd like**
`az functionapp deployment` should ideally have some checks initially to ensure that the function app is in the format that we expect it to be in and that the files have to correct permissions to avoid confusion if a customer chooses to use `az functionapp deployment` vs `func azure functionap publish`.
**Additional context**
Contributor guide
Assessment
This issue has not been assessed yet.