Control: Unused virtual network gateways should be removed
Virtual network gateways that have been idle/no connection for more than 90 days should be reviewed as these gateways are billed hourly, you should consider reconfiguring or deleting them if you don't intend to use them anymore.
Run the control in your terminal:
steampipe check azure_thrifty.control.virtual_network_gateway_unused
Snapshot and share results via Steampipe Cloud:
steampipe loginsteampipe check --share azure_thrifty.control.virtual_network_gateway_unused
Plugins & Tables
selectgateway.id as resource,casewhen gateway_connections is null then 'alarm'else 'ok'end as status,casewhen gateway_connections is null then gateway.title || ' has no connections.'else gateway.title || ' has connections.'end as reason,gateway.resource_group,display_name as subscriptionfromazure_virtual_network_gateway as gateway,azure_subscription as subwheresub.subscription_id = gateway.subscription_id;