Skip to main content

azure_data_factory_pipeline_run_resources Resource

Use the azure_data_factory_pipeline_run_resources InSpec audit resource to test the properties of multiple Azure Data Factory pipeline runs for a resource group or the entire subscription.

For additional information, see the API documentation on Azure Data Factory pipeline runs.

Azure REST API Version, Endpoint, and HTTP Client Parameters

This resource interacts with API versions supported by the resource provider. The api_version can be defined as a resource parameter. If not provided, this resource uses the latest version. For more information, refer to the azure_generic_resource document.

Unless defined, this resource uses the azure_cloud global endpoint and default values for the HTTP client. For more information, refer to the resource pack README.

Install

This resource is available in the Chef InSpec Azure resource pack.

For information on configuring your Azure environment for Chef InSpec and creating an InSpec profile that uses the InSpec Azure resource pack, see the Chef InSpec documentation for the Azure cloud platform.

Syntax

An azure_data_factory_pipeline_run_resources resource block returns all Azure Data Factory pipeline runs.

describe azure_data_factory_pipeline_run_resources(resource_group: `RESOURCE_GROUP`, factory_name: 'FACTORY_NAME') do
  #...
end

Parameters

resource_group (required)

Azure resource group where the targeted resource resides.

factory_name (required)

Azure factory name for which pipeline runs are retrieved.

Properties

invokedBy_names
A list of the unique resource names.

Field: invokedBy_name

pipelineNames
A list of the pipeline names.

Field: pipelineName

statuses
The statuses of the pipeline runs.

Field: status

runIds
The list of identifiers of runs.

Field: runId

runStart
The list of start times of pipeline runs in ISO8601 format.

Field: runStart

runEnd
The list of end times of pipeline runs in ISO8601 format.

Field: runEnd

Note

For information on using filter criteria on plural resources, see the documentation on FilterTable

Examples

Filter pipeline runs in a resource group by properties

describe azure_data_factory_pipeline_run_resources(resource_group: `RESOURCE_GROUP`, factory_name: 'FACTORY_NAME') do
  its('invokedBy_names') { should include 'INVOKED_BY_NAME' }
  its('pipelineNames') { should include 'PIPELINE_NAME' }
  its('statuses') { should include 'PIPELINE_STATUS' }
end

Matchers

Test if any pipeline runs exist in the resource group

describe azure_data_factory_pipeline_run_resources(resource_group: `RESOURCE_GROUP`, factory_name: 'FACTORY_NAME') do
  it { should exist }
end

Test that there aren’t any pipeline runs in a resource group

# Should not exist if no pipeline runs are in the resource group.

describe azure_data_factory_pipeline_run_resources(resource_group: `RESOURCE_GROUP`, factory_name: 'FACTORY_NAME') do
  it { should_not exist }
end

Azure Permissions

Your Service Principal must be set up with at least a contributor role on the subscription you wish to test.

Edit this page on GitHub

Thank you for your feedback!

×