PageSourceSearch

https://flanksource.com/assets/js/5966464c.32526b05.js

js flanksource.com collected 2026-09-25 15:26:01 UTC 13,058 bytes, 1 lines download raw bytes

1"use strict";(globalThis.webpackChunkmission_control=globalThis.webpackChunkmission_control||[]).push([[3044],{88254(e,r,s){s.r(r),s.d(r,{assets:()=>o,contentTitle:()=>d,default:()=>a,frontMatter:()=>i,metadata:()=>n,toc:()=>l});const n=JSON.parse('{"id":"guide/config-db/scrapers/azure","title":"Azure","description":"The Azure scrapers scrapes your azure account to fetch all the resources & save them as configs.","source":"@site/docs/guide/config-db/scrapers/azure.md","sourceDirName":"guide/config-db/scrapers","slug":"/guide/config-db/scrapers/azure","permalink":"/docs/guide/config-db/scrapers/azure","draft":false,"unlisted":false,"editUrl":"https://github.com/flanksource/docs/tree/main/docs/guide/config-db/scrapers/azure.md","tags":[],"version":"current","sidebarPosition":3,"frontMatter":{"title":"Azure","sidebar_position":3,"sidebar_custom_props":{"icon":"azure"}},"sidebar":"guide","previous":{"title":"AWS","permalink":"/docs/guide/config-db/scrapers/aws"},"next":{"title":"Azure Devops","permalink":"/docs/guide/config-db/scrapers/azure-devops"}}');var t=s(74848),c=s(28453);const i={title:"Azure",sidebar_position:3,sidebar_custom_props:{icon:"azure"}},d=" Azure",o={},l=[{value:"Scraper",id:"scraper",level:2},{value:"Azure",id:"azure",level:3},{value:"Exclusion",id:"exclusion",level:4},{value:"Entra",id:"entra",level:4},{value:"Resource Types",id:"resource-types",level:2}];function h(e){const r={a:"a",admonition:"admonition",code:"code",em:"em",h1:"h1",h2:"h2",h3:"h3",h4:"h4",header:"header",p:"p",pre:"pre",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,c.R)(),...e.components},{CommonLink:s,Icon:n}=r;return s||x("CommonLink",!0),n||x("Icon",!0),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(r.header,{children:(0,t.jsxs)(r.h1,{id:"-azure",children:[(0,t.jsx)(n,{name:"azure"})," Azure"]})}),"\n",(0,t.jsx)(r.p,{children:"The Azure scrapers scrapes your azure account to fetch all the resources & save them as configs."}),"\n",(0,t.jsx)(r.pre,{children:(0,t.jsx)(r.code,{className:"language-yaml",metastring:'title="azure-scraper.yaml" file=<rootDir>/modules/config-db/fixtures/azure.yaml',children:'apiVersion: configs.flanksource.com/v1\nkind: ScrapeConfig\nmetadata:\n  name: azure-scraper\nspec:\n  azure:\n    - connection: connection://azure/flanksource\n      subscriptionID: e3911016-5810-415f-b075-682db169988f\n      transform:\n        relationship:\n          # Link AKS Cluster to Kubernetes Cluster\n          - filter: config_class == \'KubernetesCluster\'\n            expr: |\n              [{\n                "type": "Kubernetes::Cluster",\n                "labels": {\n                  "aks-nodeResourceGroup": config["properties"]["nodeResourceGroup"],\n                  "subscriptionID": tags["subscriptionID"]\n                }\n              }].toJSON()\n          # Link Azure Virtual Machine Scale Sets to the Kubernetes Nodes\n          - filter: config_class == \'Node\'\n            expr: |\n              [{\n                "type": "Kubernetes::Node",\n                "labels": {\n                  "azure/vm-scale-set": name,\n                  "subscriptionID": tags["subscriptionID"]\n                }\n              }].toJSON()\n'})}),"\n",(0,t.jsx)(r.h2,{id:"scraper",children:"Scraper"}),"\n",(0,t.jsxs)(r.table,{children:[(0,t.jsx)(r.thead,{children:(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.th,{children:"Field"}),(0,t.jsx)(r.th,{children:"Description"}),(0,t.jsx)(r.th,{children:"Scheme"}),(0,t.jsx)(r.th,{children:"Required"})]})}),(0,t.jsxs)(r.tbody,{children:[(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"logLevel"})}),(0,t.jsx)(r.td,{children:"Specify the level of logging."}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"schedule"})}),(0,t.jsx)(r.td,{children:"Specify the interval to scrape in cron format. Defaults to every 60 minutes."}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"retention"})}),(0,t.jsx)(r.td,{children:"Settings for retaining changes, analysis and scraped items"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"/docs/guide/config-db/concepts/retention",children:(0,t.jsx)(r.code,{children:"Retention"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"azure"})}),(0,t.jsx)(r.td,{children:"Azure scrape config"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"#azure",children:(0,t.jsx)(r.code,{children:"[]Azure"})})}),(0,t.jsx)(r.td,{})]})]})]}),"\n",(0,t.jsx)(r.h3,{id:"azure",children:"Azure"}),"\n",(0,t.jsxs)(r.table,{children:[(0,t.jsx)(r.thead,{children:(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.th,{children:"Field"}),(0,t.jsx)(r.th,{children:"Description"}),(0,t.jsx)(r.th,{children:"Scheme"}),(0,t.jsx)(r.th,{children:"Required"})]})}),(0,t.jsxs)(r.tbody,{children:[(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"connection"})}),(0,t.jsx)(r.td,{children:"Specify the connection that provides the clientID, clientSecret & tenantID"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"subscriptionID"})}),(0,t.jsx)(r.td,{children:"Azure subscription ID"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"tenantID"})}),(0,t.jsx)(r.td,{children:"Azure tenant ID"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"clientID"})}),(0,t.jsx)(r.td,{children:"Microsoft Entra ID app client id"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(s,{to:"secrets",children:(0,t.jsx)(r.em,{children:"EnvVar"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"clientSecret"})}),(0,t.jsx)(r.td,{children:"Microsoft Entra ID app client secret"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(s,{to:"secrets",children:(0,t.jsx)(r.em,{children:"EnvVar"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"include"})}),(0,t.jsx)(r.td,{children:"Azure resources to include for scraping"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]string"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"exclusions"})}),(0,t.jsx)(r.td,{children:"Specifies the Azure resources to exclude"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"#exclusion",children:(0,t.jsx)(r.code,{children:"Exclusion"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"entra"})}),(0,t.jsx)(r.td,{children:"Microsoft Entra ID (Azure AD) scraping configuration"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"#entra",children:(0,t.jsx)(r.code,{children:"Entra"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"properties"})}),(0,t.jsx)(r.td,{children:"Custom templatable properties for the scraped config items."}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"/docs/reference/config-db/properties",children:(0,t.jsx)(r.code,{children:"[]ConfigProperty"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"transform"})}),(0,t.jsx)(r.td,{children:"Field to transform result"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.a,{href:"/docs/guide/config-db/concepts/transform",children:(0,t.jsx)(r.code,{children:"Transform"})})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"tags"})}),(0,t.jsx)(r.td,{children:"Set custom tags on the scraped config items"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"map[string]string"})}),(0,t.jsx)(r.td,{})]})]})]}),"\n",(0,t.jsx)(r.admonition,{type:"note",children:(0,t.jsxs)(r.p,{children:["Either the ",(0,t.jsx)(r.code,{children:"connection"})," name or the credentials (",(0,t.jsx)(r.code,{children:"clientID"}),", ",(0,t.jsx)(r.code,{children:"clientSecret"})," & ",(0,t.jsx)(r.code,{children:"tenantID"}),") are required"]})}),"\n",(0,t.jsx)(r.h4,{id:"exclusion",children:"Exclusion"}),"\n",(0,t.jsxs)(r.table,{children:[(0,t.jsx)(r.thead,{children:(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.th,{children:"Field"}),(0,t.jsx)(r.th,{children:"Description"}),(0,t.jsx)(r.th,{children:"Scheme"}),(0,t.jsx)(r.th,{children:"Required"})]})}),(0,t.jsx)(r.tbody,{children:(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"activityLogs"})}),(0,t.jsx)(r.td,{children:"A list of operations to exclude from activity logs"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]string"})}),(0,t.jsx)(r.td,{})]})})]}),"\n",(0,t.jsx)(r.h4,{id:"entra",children:"Entra"}),"\n",(0,t.jsxs)(r.table,{children:[(0,t.jsx)(r.thead,{children:(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.th,{children:"Field"}),(0,t.jsx)(r.th,{children:"Description"}),(0,t.jsx)(r.th,{children:"Scheme"}),(0,t.jsx)(r.th,{children:"Required"})]})}),(0,t.jsxs)(r.tbody,{children:[(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"users"})}),(0,t.jsx)(r.td,{children:"Selectors for scraping Entra ID users"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]ResourceSelector"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"groups"})}),(0,t.jsx)(r.td,{children:"Selectors for scraping Entra ID groups"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]ResourceSelector"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"appRegistrations"})}),(0,t.jsx)(r.td,{children:"Selectors for scraping app registrations"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]ResourceSelector"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"enterpriseApps"})}),(0,t.jsx)(r.td,{children:"Selectors for scraping enterprise applications"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]ResourceSelector"})}),(0,t.jsx)(r.td,{})]}),(0,t.jsxs)(r.tr,{children:[(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"appRoleAssignments"})}),(0,t.jsx)(r.td,{children:"Selectors for scraping app role assignments"}),(0,t.jsx)(r.td,{children:(0,t.jsx)(r.code,{children:"[]ResourceSelector"})}),(0,t.jsx)(r.td,{})]})]})]}),"\n",(0,t.jsx)(r.h2,{id:"resource-types",children:"Resource Types"}),"\n",(0,t.jsx)(r.p,{children:"The following Azure resources are scraped and mapped to Mission Control config types:"}),"\n",(0,t.jsx)(r.p,{children:"| Resource Type                              | Config 
1Class          |\n| ------------------------------------------ | --------------------- | --- |\n| microsoft.compute/virtualmachines          | VirtualMachine        |\n| microsoft.compute/virtualmachinescalesets  | Node                  |\n| microsoft.network/loadbalancers            | LoadBalancer          |\n| microsoft.network/virtualnetworks          | VirtualNetwork        |\n| microsoft.containerregistry/registries     | ContainerRegistry     |\n| microsoft.network/azurefirewalls           | Firewall              |\n| microsoft.sql/servers                      | RelationalDatabase    |\n| microsoft.dbforpostgresql/servers          | RelationalDatabase    |\n| microsoft.containerservice/managedclusters | KubernetesCluster     |\n| microsoft.resources/resourcegroups         | ResourceGroup         |\n| subscription                               | Subscription          |\n| microsoft.storage/storageaccounts          | StorageAccount        |\n| microsoft.web/sites                        | AppService            |\n| microsoft.network/dnszones                 | DNSZone               |\n| microsoft.network/privatednszones          | PrivateDNSZone        |\n| microsoft.network/trafficmanagerprofiles   | TrafficManagerProfile |\n| microsoft.network/networksecuritygroups    | SecurityGroup         |\n| microsoft.network/publicipaddresses        | PublicIPAddress       | +   |"})]})}function a(e={}){const{wrapper:r}={...(0,c.R)(),...e.components};return r?(0,t.jsx)(r,{...e,children:(0,t.jsx)(h,{...e})}):h(e)}function x(e,r){throw new Error("Expected "+(r?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},28453(e,r,s){s.d(r,{R:()=>i,x:()=>d});var n=s(96540);const t={},c=n.createContext(t);function i(e){const r=n.useContext(c);return n.useMemo(function(){return"function"==typeof e?e(r):{...r,...e}},[r,e])}function d(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:i(e.components),n.createElement(c.Provider,{value:r},e.children)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.