azure-native.insights.SubscriptionDiagnosticSetting
Explore with Pulumi AI
The subscription diagnostic setting resource. Azure REST API version: 2021-05-01-preview. Prior API version in Azure Native 1.x: 2017-05-01-preview.
Other available API versions: 2017-05-01-preview.
Example Usage
Creates or Updates the subscription diagnostic setting
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() => 
{
    var subscriptionDiagnosticSetting = new AzureNative.Insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", new()
    {
        EventHubAuthorizationRuleId = "/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
        EventHubName = "myeventhub",
        Logs = new[]
        {
            new AzureNative.Insights.Inputs.SubscriptionLogSettingsArgs
            {
                CategoryGroup = "allLogs",
                Enabled = true,
            },
        },
        MarketplacePartnerId = "/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
        Name = "ds4",
        StorageAccountId = "/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
        WorkspaceId = "",
    });
});
package main
import (
	insights "github.com/pulumi/pulumi-azure-native-sdk/insights/v2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := insights.NewSubscriptionDiagnosticSetting(ctx, "subscriptionDiagnosticSetting", &insights.SubscriptionDiagnosticSettingArgs{
			EventHubAuthorizationRuleId: pulumi.String("/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule"),
			EventHubName:                pulumi.String("myeventhub"),
			Logs: insights.SubscriptionLogSettingsArray{
				&insights.SubscriptionLogSettingsArgs{
					CategoryGroup: pulumi.String("allLogs"),
					Enabled:       pulumi.Bool(true),
				},
			},
			MarketplacePartnerId: pulumi.String("/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1"),
			Name:                 pulumi.String("ds4"),
			StorageAccountId:     pulumi.String("/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1"),
			WorkspaceId:          pulumi.String(""),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.insights.SubscriptionDiagnosticSetting;
import com.pulumi.azurenative.insights.SubscriptionDiagnosticSettingArgs;
import com.pulumi.azurenative.insights.inputs.SubscriptionLogSettingsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }
    public static void stack(Context ctx) {
        var subscriptionDiagnosticSetting = new SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", SubscriptionDiagnosticSettingArgs.builder()
            .eventHubAuthorizationRuleId("/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule")
            .eventHubName("myeventhub")
            .logs(SubscriptionLogSettingsArgs.builder()
                .categoryGroup("allLogs")
                .enabled(true)
                .build())
            .marketplacePartnerId("/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1")
            .name("ds4")
            .storageAccountId("/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1")
            .workspaceId("")
            .build());
    }
}
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const subscriptionDiagnosticSetting = new azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", {
    eventHubAuthorizationRuleId: "/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
    eventHubName: "myeventhub",
    logs: [{
        categoryGroup: "allLogs",
        enabled: true,
    }],
    marketplacePartnerId: "/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
    name: "ds4",
    storageAccountId: "/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
    workspaceId: "",
});
import pulumi
import pulumi_azure_native as azure_native
subscription_diagnostic_setting = azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting",
    event_hub_authorization_rule_id="/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
    event_hub_name="myeventhub",
    logs=[{
        "category_group": "allLogs",
        "enabled": True,
    }],
    marketplace_partner_id="/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
    name="ds4",
    storage_account_id="/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
    workspace_id="")
resources:
  subscriptionDiagnosticSetting:
    type: azure-native:insights:SubscriptionDiagnosticSetting
    properties:
      eventHubAuthorizationRuleId: /subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule
      eventHubName: myeventhub
      logs:
        - categoryGroup: allLogs
          enabled: true
      marketplacePartnerId: /subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1
      name: ds4
      storageAccountId: /subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1
      workspaceId: ""
Creates or Updates the subscription diagnostic setting for category
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() => 
{
    var subscriptionDiagnosticSetting = new AzureNative.Insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", new()
    {
        EventHubAuthorizationRuleId = "/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
        EventHubName = "myeventhub",
        Logs = new[]
        {
            new AzureNative.Insights.Inputs.SubscriptionLogSettingsArgs
            {
                Category = "Security",
                Enabled = true,
            },
        },
        MarketplacePartnerId = "/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
        Name = "ds4",
        StorageAccountId = "/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
        WorkspaceId = "",
    });
});
package main
import (
	insights "github.com/pulumi/pulumi-azure-native-sdk/insights/v2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := insights.NewSubscriptionDiagnosticSetting(ctx, "subscriptionDiagnosticSetting", &insights.SubscriptionDiagnosticSettingArgs{
			EventHubAuthorizationRuleId: pulumi.String("/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule"),
			EventHubName:                pulumi.String("myeventhub"),
			Logs: insights.SubscriptionLogSettingsArray{
				&insights.SubscriptionLogSettingsArgs{
					Category: pulumi.String("Security"),
					Enabled:  pulumi.Bool(true),
				},
			},
			MarketplacePartnerId: pulumi.String("/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1"),
			Name:                 pulumi.String("ds4"),
			StorageAccountId:     pulumi.String("/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1"),
			WorkspaceId:          pulumi.String(""),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.insights.SubscriptionDiagnosticSetting;
import com.pulumi.azurenative.insights.SubscriptionDiagnosticSettingArgs;
import com.pulumi.azurenative.insights.inputs.SubscriptionLogSettingsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }
    public static void stack(Context ctx) {
        var subscriptionDiagnosticSetting = new SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", SubscriptionDiagnosticSettingArgs.builder()
            .eventHubAuthorizationRuleId("/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule")
            .eventHubName("myeventhub")
            .logs(SubscriptionLogSettingsArgs.builder()
                .category("Security")
                .enabled(true)
                .build())
            .marketplacePartnerId("/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1")
            .name("ds4")
            .storageAccountId("/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1")
            .workspaceId("")
            .build());
    }
}
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const subscriptionDiagnosticSetting = new azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting", {
    eventHubAuthorizationRuleId: "/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
    eventHubName: "myeventhub",
    logs: [{
        category: "Security",
        enabled: true,
    }],
    marketplacePartnerId: "/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
    name: "ds4",
    storageAccountId: "/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
    workspaceId: "",
});
import pulumi
import pulumi_azure_native as azure_native
subscription_diagnostic_setting = azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSetting",
    event_hub_authorization_rule_id="/subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule",
    event_hub_name="myeventhub",
    logs=[{
        "category": "Security",
        "enabled": True,
    }],
    marketplace_partner_id="/subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1",
    name="ds4",
    storage_account_id="/subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1",
    workspace_id="")
resources:
  subscriptionDiagnosticSetting:
    type: azure-native:insights:SubscriptionDiagnosticSetting
    properties:
      eventHubAuthorizationRuleId: /subscriptions/fb9f25f9-5785-4510-a38f-a62f188eb9f8/resourceGroups/montest/providers/microsoft.eventhub/namespaces/mynamespace/authorizationrules/myrule
      eventHubName: myeventhub
      logs:
        - category: Security
          enabled: true
      marketplacePartnerId: /subscriptions/abcdeabc-1234-1234-ab12-123a1234567a/resourceGroups/test-rg/providers/Microsoft.Datadog/monitors/dd1
      name: ds4
      storageAccountId: /subscriptions/df602c9c-7aa0-407d-a6fb-eb20c8bd1192/resourceGroups/apptest/providers/Microsoft.Storage/storageAccounts/appteststorage1
      workspaceId: ""
Create SubscriptionDiagnosticSetting Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SubscriptionDiagnosticSetting(name: string, args?: SubscriptionDiagnosticSettingArgs, opts?: CustomResourceOptions);@overload
def SubscriptionDiagnosticSetting(resource_name: str,
                                  args: Optional[SubscriptionDiagnosticSettingArgs] = None,
                                  opts: Optional[ResourceOptions] = None)
@overload
def SubscriptionDiagnosticSetting(resource_name: str,
                                  opts: Optional[ResourceOptions] = None,
                                  event_hub_authorization_rule_id: Optional[str] = None,
                                  event_hub_name: Optional[str] = None,
                                  logs: Optional[Sequence[SubscriptionLogSettingsArgs]] = None,
                                  marketplace_partner_id: Optional[str] = None,
                                  name: Optional[str] = None,
                                  service_bus_rule_id: Optional[str] = None,
                                  storage_account_id: Optional[str] = None,
                                  workspace_id: Optional[str] = None)func NewSubscriptionDiagnosticSetting(ctx *Context, name string, args *SubscriptionDiagnosticSettingArgs, opts ...ResourceOption) (*SubscriptionDiagnosticSetting, error)public SubscriptionDiagnosticSetting(string name, SubscriptionDiagnosticSettingArgs? args = null, CustomResourceOptions? opts = null)
public SubscriptionDiagnosticSetting(String name, SubscriptionDiagnosticSettingArgs args)
public SubscriptionDiagnosticSetting(String name, SubscriptionDiagnosticSettingArgs args, CustomResourceOptions options)
type: azure-native:insights:SubscriptionDiagnosticSetting
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SubscriptionDiagnosticSettingArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SubscriptionDiagnosticSettingArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SubscriptionDiagnosticSettingArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SubscriptionDiagnosticSettingArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SubscriptionDiagnosticSettingArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var subscriptionDiagnosticSettingResource = new AzureNative.Insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSettingResource", new()
{
    EventHubAuthorizationRuleId = "string",
    EventHubName = "string",
    Logs = new[]
    {
        new AzureNative.Insights.Inputs.SubscriptionLogSettingsArgs
        {
            Enabled = false,
            Category = "string",
            CategoryGroup = "string",
        },
    },
    MarketplacePartnerId = "string",
    Name = "string",
    ServiceBusRuleId = "string",
    StorageAccountId = "string",
    WorkspaceId = "string",
});
example, err := insights.NewSubscriptionDiagnosticSetting(ctx, "subscriptionDiagnosticSettingResource", &insights.SubscriptionDiagnosticSettingArgs{
	EventHubAuthorizationRuleId: pulumi.String("string"),
	EventHubName:                pulumi.String("string"),
	Logs: insights.SubscriptionLogSettingsArray{
		&insights.SubscriptionLogSettingsArgs{
			Enabled:       pulumi.Bool(false),
			Category:      pulumi.String("string"),
			CategoryGroup: pulumi.String("string"),
		},
	},
	MarketplacePartnerId: pulumi.String("string"),
	Name:                 pulumi.String("string"),
	ServiceBusRuleId:     pulumi.String("string"),
	StorageAccountId:     pulumi.String("string"),
	WorkspaceId:          pulumi.String("string"),
})
var subscriptionDiagnosticSettingResource = new SubscriptionDiagnosticSetting("subscriptionDiagnosticSettingResource", SubscriptionDiagnosticSettingArgs.builder()
    .eventHubAuthorizationRuleId("string")
    .eventHubName("string")
    .logs(SubscriptionLogSettingsArgs.builder()
        .enabled(false)
        .category("string")
        .categoryGroup("string")
        .build())
    .marketplacePartnerId("string")
    .name("string")
    .serviceBusRuleId("string")
    .storageAccountId("string")
    .workspaceId("string")
    .build());
subscription_diagnostic_setting_resource = azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSettingResource",
    event_hub_authorization_rule_id="string",
    event_hub_name="string",
    logs=[{
        "enabled": False,
        "category": "string",
        "category_group": "string",
    }],
    marketplace_partner_id="string",
    name="string",
    service_bus_rule_id="string",
    storage_account_id="string",
    workspace_id="string")
const subscriptionDiagnosticSettingResource = new azure_native.insights.SubscriptionDiagnosticSetting("subscriptionDiagnosticSettingResource", {
    eventHubAuthorizationRuleId: "string",
    eventHubName: "string",
    logs: [{
        enabled: false,
        category: "string",
        categoryGroup: "string",
    }],
    marketplacePartnerId: "string",
    name: "string",
    serviceBusRuleId: "string",
    storageAccountId: "string",
    workspaceId: "string",
});
type: azure-native:insights:SubscriptionDiagnosticSetting
properties:
    eventHubAuthorizationRuleId: string
    eventHubName: string
    logs:
        - category: string
          categoryGroup: string
          enabled: false
    marketplacePartnerId: string
    name: string
    serviceBusRuleId: string
    storageAccountId: string
    workspaceId: string
SubscriptionDiagnosticSetting Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The SubscriptionDiagnosticSetting resource accepts the following input properties:
- string
- The resource Id for the event hub authorization rule.
- EventHub stringName 
- The name of the event hub. If none is specified, the default event hub will be selected.
- Logs
List<Pulumi.Azure Native. Insights. Inputs. Subscription Log Settings> 
- The list of logs settings.
- MarketplacePartner stringId 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- Name string
- The name of the diagnostic setting.
- ServiceBus stringRule Id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- StorageAccount stringId 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- WorkspaceId string
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
- string
- The resource Id for the event hub authorization rule.
- EventHub stringName 
- The name of the event hub. If none is specified, the default event hub will be selected.
- Logs
[]SubscriptionLog Settings Args 
- The list of logs settings.
- MarketplacePartner stringId 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- Name string
- The name of the diagnostic setting.
- ServiceBus stringRule Id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- StorageAccount stringId 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- WorkspaceId string
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
- String
- The resource Id for the event hub authorization rule.
- eventHub StringName 
- The name of the event hub. If none is specified, the default event hub will be selected.
- logs
List<SubscriptionLog Settings> 
- The list of logs settings.
- marketplacePartner StringId 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- name String
- The name of the diagnostic setting.
- serviceBus StringRule Id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- storageAccount StringId 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- workspaceId String
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
- string
- The resource Id for the event hub authorization rule.
- eventHub stringName 
- The name of the event hub. If none is specified, the default event hub will be selected.
- logs
SubscriptionLog Settings[] 
- The list of logs settings.
- marketplacePartner stringId 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- name string
- The name of the diagnostic setting.
- serviceBus stringRule Id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- storageAccount stringId 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- workspaceId string
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
- str
- The resource Id for the event hub authorization rule.
- event_hub_ strname 
- The name of the event hub. If none is specified, the default event hub will be selected.
- logs
Sequence[SubscriptionLog Settings Args] 
- The list of logs settings.
- marketplace_partner_ strid 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- name str
- The name of the diagnostic setting.
- service_bus_ strrule_ id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- storage_account_ strid 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- workspace_id str
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
- String
- The resource Id for the event hub authorization rule.
- eventHub StringName 
- The name of the event hub. If none is specified, the default event hub will be selected.
- logs List<Property Map>
- The list of logs settings.
- marketplacePartner StringId 
- The full ARM resource ID of the Marketplace resource to which you would like to send Diagnostic Logs.
- name String
- The name of the diagnostic setting.
- serviceBus StringRule Id 
- The service bus rule Id of the diagnostic setting. This is here to maintain backwards compatibility.
- storageAccount StringId 
- The resource ID of the storage account to which you would like to send Diagnostic Logs.
- workspaceId String
- The full ARM resource ID of the Log Analytics workspace to which you would like to send Diagnostic Logs. Example: /subscriptions/4b9e8510-67ab-4e9a-95a9-e2f1e570ea9c/resourceGroups/insights-integration/providers/Microsoft.OperationalInsights/workspaces/viruela2
Outputs
All input properties are implicitly available as output properties. Additionally, the SubscriptionDiagnosticSetting resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- SystemData Pulumi.Azure Native. Insights. Outputs. System Data Response 
- The system metadata related to this resource.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Id string
- The provider-assigned unique ID for this managed resource.
- SystemData SystemData Response 
- The system metadata related to this resource.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id String
- The provider-assigned unique ID for this managed resource.
- systemData SystemData Response 
- The system metadata related to this resource.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id string
- The provider-assigned unique ID for this managed resource.
- systemData SystemData Response 
- The system metadata related to this resource.
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id str
- The provider-assigned unique ID for this managed resource.
- system_data SystemData Response 
- The system metadata related to this resource.
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- id String
- The provider-assigned unique ID for this managed resource.
- systemData Property Map
- The system metadata related to this resource.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
Supporting Types
SubscriptionLogSettings, SubscriptionLogSettingsArgs      
- Enabled bool
- a value indicating whether this log is enabled.
- Category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- CategoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- Enabled bool
- a value indicating whether this log is enabled.
- Category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- CategoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled Boolean
- a value indicating whether this log is enabled.
- category String
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup String
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled boolean
- a value indicating whether this log is enabled.
- category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled bool
- a value indicating whether this log is enabled.
- category str
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- category_group str
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled Boolean
- a value indicating whether this log is enabled.
- category String
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup String
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
SubscriptionLogSettingsResponse, SubscriptionLogSettingsResponseArgs        
- Enabled bool
- a value indicating whether this log is enabled.
- Category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- CategoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- Enabled bool
- a value indicating whether this log is enabled.
- Category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- CategoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled Boolean
- a value indicating whether this log is enabled.
- category String
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup String
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled boolean
- a value indicating whether this log is enabled.
- category string
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup string
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled bool
- a value indicating whether this log is enabled.
- category str
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- category_group str
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
- enabled Boolean
- a value indicating whether this log is enabled.
- category String
- Name of a Subscription Diagnostic Log category for a resource type this setting is applied to.
- categoryGroup String
- Name of a Subscription Diagnostic Log category group for a resource type this setting is applied to.
SystemDataResponse, SystemDataResponseArgs      
- CreatedAt string
- The timestamp of resource creation (UTC).
- CreatedBy string
- The identity that created the resource.
- CreatedBy stringType 
- The type of identity that created the resource.
- LastModified stringAt 
- The timestamp of resource last modification (UTC)
- LastModified stringBy 
- The identity that last modified the resource.
- LastModified stringBy Type 
- The type of identity that last modified the resource.
- CreatedAt string
- The timestamp of resource creation (UTC).
- CreatedBy string
- The identity that created the resource.
- CreatedBy stringType 
- The type of identity that created the resource.
- LastModified stringAt 
- The timestamp of resource last modification (UTC)
- LastModified stringBy 
- The identity that last modified the resource.
- LastModified stringBy Type 
- The type of identity that last modified the resource.
- createdAt String
- The timestamp of resource creation (UTC).
- createdBy String
- The identity that created the resource.
- createdBy StringType 
- The type of identity that created the resource.
- lastModified StringAt 
- The timestamp of resource last modification (UTC)
- lastModified StringBy 
- The identity that last modified the resource.
- lastModified StringBy Type 
- The type of identity that last modified the resource.
- createdAt string
- The timestamp of resource creation (UTC).
- createdBy string
- The identity that created the resource.
- createdBy stringType 
- The type of identity that created the resource.
- lastModified stringAt 
- The timestamp of resource last modification (UTC)
- lastModified stringBy 
- The identity that last modified the resource.
- lastModified stringBy Type 
- The type of identity that last modified the resource.
- created_at str
- The timestamp of resource creation (UTC).
- created_by str
- The identity that created the resource.
- created_by_ strtype 
- The type of identity that created the resource.
- last_modified_ strat 
- The timestamp of resource last modification (UTC)
- last_modified_ strby 
- The identity that last modified the resource.
- last_modified_ strby_ type 
- The type of identity that last modified the resource.
- createdAt String
- The timestamp of resource creation (UTC).
- createdBy String
- The identity that created the resource.
- createdBy StringType 
- The type of identity that created the resource.
- lastModified StringAt 
- The timestamp of resource last modification (UTC)
- lastModified StringBy 
- The identity that last modified the resource.
- lastModified StringBy Type 
- The type of identity that last modified the resource.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:insights:SubscriptionDiagnosticSetting ds4 /subscriptions/{subscriptionId}/providers/Microsoft.Insights/diagnosticSettings/{name} 
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0