flow_logs
Creates, updates, deletes, gets or lists a flow_logs
resource.
Overview
Name | flow_logs |
Type | Resource |
Id | azure.network.flow_logs |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Request successful. The operation returns a flow log resource.
Name | Datatype | Description |
---|---|---|
id | string (arm-id) | Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" |
name | string | The name of the resource |
etag | string | A unique read-only string that changes whenever the resource is updated. |
identity | object | FlowLog resource Managed Identity |
properties | object | Properties of the flow log. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" |
Successful flow log enumeration request.
Name | Datatype | Description |
---|---|---|
id | string (arm-id) | Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" |
name | string | The name of the resource |
etag | string | A unique read-only string that changes whenever the resource is updated. |
identity | object | FlowLog resource Managed Identity |
properties | object | Properties of the flow log. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | resourceGroupName , networkWatcherName , flowLogName , subscriptionId | Gets a flow log resource by name. | |
list | select | resourceGroupName , networkWatcherName , subscriptionId | Lists all flow log resources for the specified Network Watcher. | |
create_or_update | insert | resourceGroupName , networkWatcherName , flowLogName , subscriptionId | Create or update a flow log for the specified network security group. | |
delete | delete | resourceGroupName , networkWatcherName , flowLogName , subscriptionId | Deletes the specified flow log resource. | |
update_tags | exec | resourceGroupName , networkWatcherName , flowLogName , subscriptionId | Update tags of the specified flow log. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
flowLogName | string | The name of the flow log. |
networkWatcherName | string | The name of the network watcher. |
resourceGroupName | string | The name of the resource group. |
subscriptionId | string (uuid) | The ID of the target subscription. The value must be an UUID. |
SELECT
examples
- get
- list
Gets a flow log resource by name.
SELECT
id,
name,
etag,
identity,
properties,
systemData,
type
FROM azure.network.flow_logs
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND networkWatcherName = '{{ networkWatcherName }}' -- required
AND flowLogName = '{{ flowLogName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Lists all flow log resources for the specified Network Watcher.
SELECT
id,
name,
etag,
identity,
properties,
systemData,
type
FROM azure.network.flow_logs
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND networkWatcherName = '{{ networkWatcherName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create_or_update
- Manifest
Create or update a flow log for the specified network security group.
INSERT INTO azure.network.flow_logs (
data__properties,
data__identity,
resourceGroupName,
networkWatcherName,
flowLogName,
subscriptionId
)
SELECT
'{{ properties }}',
'{{ identity }}',
'{{ resourceGroupName }}',
'{{ networkWatcherName }}',
'{{ flowLogName }}',
'{{ subscriptionId }}'
RETURNING
id,
name,
etag,
identity,
properties,
systemData,
type
;
# Description fields are for documentation purposes
- name: flow_logs
props:
- name: resourceGroupName
value: string
description: Required parameter for the flow_logs resource.
- name: networkWatcherName
value: string
description: Required parameter for the flow_logs resource.
- name: flowLogName
value: string
description: Required parameter for the flow_logs resource.
- name: subscriptionId
value: string (uuid)
description: Required parameter for the flow_logs resource.
- name: properties
value: object
description: |
Properties of the flow log.
- name: identity
value: object
description: |
FlowLog resource Managed Identity
DELETE
examples
- delete
Deletes the specified flow log resource.
DELETE FROM azure.network.flow_logs
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND networkWatcherName = '{{ networkWatcherName }}' --required
AND flowLogName = '{{ flowLogName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
;
Lifecycle Methods
- update_tags
Update tags of the specified flow log.
EXEC azure.network.flow_logs.update_tags
@resourceGroupName='{{ resourceGroupName }}' --required,
@networkWatcherName='{{ networkWatcherName }}' --required,
@flowLogName='{{ flowLogName }}' --required,
@subscriptionId='{{ subscriptionId }}' --required
@@json=
'{
"tags": "{{ tags }}"
}'
;