Azure ARM deployment fails when GitHub repo has branch protection rules
- Dominant language
- No language data
- Stars
- 346
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
## Issue
I had a GitHub branch that had a protection rule not allowing direct commits. I attempted to deploy a Static Web App that connects to that branch and received this vague error message when deploying:

With the error message:
```
{
"status": "Failed",
"error": {
"code": "InternalServerError",
"message": "There was an unexpected InternalServerError. Please try again later. x-ms-correlation-request-id: e1aa095e-368c-4e79-9a8a-dacc435580dd"
}
}
```
Upon removing the branch protection policy the static web app deployed successfully.
## Proposed Solution
I propose either of the following when a branch protection policy is present:
- An error message is raised when first selecting that branch that states a branch protection policy is present and you need to remove it.
- When you deploy, instead of directly committing you are given the option to open a PR from a new branch with the workflow
- You are given the option to deploy without a workflow file and go commit/PR your own.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.