Hi, Logan!
It is not possible to fully manage deployment permissions using Terraform alone, especially when the goal is to restrict deployments to a specific service principal. Azure Policy does not have the capability to enforce policies based on who is performing the deployment action at runtime, it only evaluates the state of the resources being deployed or modified.
The best approach in this scenario is to manage access control through Azure RBAC (Role-Based Access Control). By assigning the required Contributor (or equivalent) role only to the Terraform service principal and limiting all other users/groups to Reader or minimal permissions, you can effectively ensure that only Terraform is allowed to deploy and modify resources.