Skip to content
This Python solution initiates an on-demand Azure Policy evaluation on the specified subscription
Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE
README.md
azure_policy_evaluate.py

README.md

Azure Policy On-Demand Evaluation

This Python solution initiates an on-demand Azure Policy evaluation on the specified subscription

What problem does this solve?

Azure Policy is a service used to enforce governance and compliance in Microsoft Azure. Evaluation of policy is performed automatically under the circumstances referenced in this article. At this time, initiating an on-demand scan requires a request to the Azure REST API.

This Python solution can be used to initiate an on-demand scan. Be aware on-demand evaluations can take anywhere from 5-10 minutes to complete.

Requirements

Python Runtime and Modules

Azure Requirements

Setup

Ensure the appropriate Python modules are installed.

python azure_policy_evaluate.py --tenantname TENANTNAME --clientid CLIENTID --clientsecret CLIENTSECRET --subscriptionid SUB_ID [--logfile]

You can’t perform that action at this time.