turbot/azure_compliance

Query: appservice_web_app_worker_more_than_one

Usage

powerpipe query azure_compliance.query.appservice_web_app_worker_more_than_one

SQL

select
p ->> 'ID' as resource,
case
when (p -> 'SiteProperties' -> 'siteConfig' ->> 'numberOfWorkers')::int > 1 then 'ok'
else 'alarm'
end as status,
a.name || ' has ' || (p -> 'SiteProperties' -> 'siteConfig' ->> 'numberOfWorkers') || ' no of worker(s).' as reason
, a.resource_group as resource_group
, sub.display_name as subscription
from
azure_app_service_plan as a,
jsonb_array_elements(apps) as p,
azure_subscription as sub
where
sub.subscription_id = a.subscription_id;

Controls

The query is being used by the following controls: