import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages a Log Analytics (formally Operational Insights) Workspace. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "West Europe", * }); * const exampleAnalyticsWorkspace = new azure.operationalinsights.AnalyticsWorkspace("example", { * name: "example", * location: example.location, * resourceGroupName: example.name, * sku: "PerGB2018", * retentionInDays: 30, * }); * ``` * * ## API Providers * * * This resource uses the following Azure API Providers: * * * `Microsoft.OperationalInsights` - 2022-10-01, 2020-08-01 * * ## Import * * Log Analytics Workspaces can be imported using the `resource id`, e.g. * * ```sh * $ pulumi import azure:operationalinsights/analyticsWorkspace:AnalyticsWorkspace workspace1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.OperationalInsights/workspaces/workspace1 * ``` */ export declare class AnalyticsWorkspace extends pulumi.CustomResource { /** * Get an existing AnalyticsWorkspace resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: AnalyticsWorkspaceState, opts?: pulumi.CustomResourceOptions): AnalyticsWorkspace; /** * Returns true if the given object is an instance of AnalyticsWorkspace. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is AnalyticsWorkspace; /** * Specifies if the log Analytics Workspace allows users accessing to data associated with the resources they have permission to view, without permission to workspace. Defaults to `true`. */ readonly allowResourceOnlyPermissions: pulumi.Output; /** * Is Customer Managed Storage mandatory for query management? */ readonly cmkForQueryForced: pulumi.Output; /** * The workspace daily quota for ingestion in GB. Defaults to `-1` (unlimited) if omitted. */ readonly dailyQuotaGb: pulumi.Output; /** * The ID of the Data Collection Rule to use for this workspace. */ readonly dataCollectionRuleId: pulumi.Output; /** * An `identity` block as defined below. */ readonly identity: pulumi.Output; /** * Whether to remove the data in the Log Analytics Workspace immediately after 30 days. */ readonly immediateDataPurgeOn30DaysEnabled: pulumi.Output; /** * Should the Log Analytics Workspace support ingestion over the Public Internet? Defaults to `true`. */ readonly internetIngestionEnabled: pulumi.Output; /** * Should the Log Analytics Workspace support querying over the Public Internet? Defaults to `true`. */ readonly internetQueryEnabled: pulumi.Output; /** * @deprecated `localAuthenticationDisabled` has been deprecated in favour of `localAuthenticationEnabled` and will be removed in v5.0 of the AzureRM Provider */ readonly localAuthenticationDisabled: pulumi.Output; /** * Specifies if the log Analytics workspace should allow local authentication methods in addition to Microsoft Entra (Azure AD). Defaults to `true`. */ readonly localAuthenticationEnabled: pulumi.Output; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ readonly location: pulumi.Output; /** * Specifies the name of the Log Analytics Workspace. Workspace name should include 4-63 letters, digits or '-'. The '-' shouldn't be the first or the last symbol. Changing this forces a new resource to be created. */ readonly name: pulumi.Output; /** * The Primary shared key for the Log Analytics Workspace. */ readonly primarySharedKey: pulumi.Output; /** * The capacity reservation level in GB for this workspace. Possible values are `100`, `200`, `300`, `400`, `500`, `1000`, `2000` and `5000`. * * > **Note:** `reservationCapacityInGbPerDay` can only be used when the `sku` is set to `CapacityReservation`. */ readonly reservationCapacityInGbPerDay: pulumi.Output; /** * The name of the resource group in which the Log Analytics workspace is created. Changing this forces a new resource to be created. */ readonly resourceGroupName: pulumi.Output; /** * The workspace data retention in days. Possible values are between `30` and `730`. */ readonly retentionInDays: pulumi.Output; /** * The Secondary shared key for the Log Analytics Workspace. */ readonly secondarySharedKey: pulumi.Output; /** * Specifies the SKU of the Log Analytics Workspace. Possible values are `PerGB2018`, `PerNode`, `Premium`, `Standalone`, `Standard`, `CapacityReservation`, `LACluster` and `Unlimited`. Defaults to `PerGB2018`. * * > **Note:** `sku` should only be set to `LACluster` when the Log Analytics Workspace is linked to a Log Analytics Cluster. Additionally, `sku` cannot be modified while linked. * * > **Note:** Changing `sku` forces a new Log Analytics Workspace to be created, except when changing between `PerGB2018` and `CapacityReservation`. Changing `sku` to `CapacityReservation` or changing `reservationCapacityInGbPerDay` to a higher tier will lead to a 31-days commitment period, during which the SKU cannot be changed to a lower one. Please refer to [official documentation](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/cost-logs#commitment-tiers) for further information. * * > **Note:** A new pricing model took effect on `2018-04-03`, which requires the SKU `PerGB2018`. If you've provisioned resources before this date you have the option of remaining with the previous Pricing SKU and using the other SKUs defined above. More information about [the Pricing SKUs is available at the following URI](https://aka.ms/PricingTierWarning). */ readonly sku: pulumi.Output; /** * A mapping of tags to assign to the resource. */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * The Workspace (or Customer) ID for the Log Analytics Workspace. */ readonly workspaceId: pulumi.Output; /** * Create a AnalyticsWorkspace resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: AnalyticsWorkspaceArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering AnalyticsWorkspace resources. */ export interface AnalyticsWorkspaceState { /** * Specifies if the log Analytics Workspace allows users accessing to data associated with the resources they have permission to view, without permission to workspace. Defaults to `true`. */ allowResourceOnlyPermissions?: pulumi.Input; /** * Is Customer Managed Storage mandatory for query management? */ cmkForQueryForced?: pulumi.Input; /** * The workspace daily quota for ingestion in GB. Defaults to `-1` (unlimited) if omitted. */ dailyQuotaGb?: pulumi.Input; /** * The ID of the Data Collection Rule to use for this workspace. */ dataCollectionRuleId?: pulumi.Input; /** * An `identity` block as defined below. */ identity?: pulumi.Input; /** * Whether to remove the data in the Log Analytics Workspace immediately after 30 days. */ immediateDataPurgeOn30DaysEnabled?: pulumi.Input; /** * Should the Log Analytics Workspace support ingestion over the Public Internet? Defaults to `true`. */ internetIngestionEnabled?: pulumi.Input; /** * Should the Log Analytics Workspace support querying over the Public Internet? Defaults to `true`. */ internetQueryEnabled?: pulumi.Input; /** * @deprecated `localAuthenticationDisabled` has been deprecated in favour of `localAuthenticationEnabled` and will be removed in v5.0 of the AzureRM Provider */ localAuthenticationDisabled?: pulumi.Input; /** * Specifies if the log Analytics workspace should allow local authentication methods in addition to Microsoft Entra (Azure AD). Defaults to `true`. */ localAuthenticationEnabled?: pulumi.Input; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ location?: pulumi.Input; /** * Specifies the name of the Log Analytics Workspace. Workspace name should include 4-63 letters, digits or '-'. The '-' shouldn't be the first or the last symbol. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * The Primary shared key for the Log Analytics Workspace. */ primarySharedKey?: pulumi.Input; /** * The capacity reservation level in GB for this workspace. Possible values are `100`, `200`, `300`, `400`, `500`, `1000`, `2000` and `5000`. * * > **Note:** `reservationCapacityInGbPerDay` can only be used when the `sku` is set to `CapacityReservation`. */ reservationCapacityInGbPerDay?: pulumi.Input; /** * The name of the resource group in which the Log Analytics workspace is created. Changing this forces a new resource to be created. */ resourceGroupName?: pulumi.Input; /** * The workspace data retention in days. Possible values are between `30` and `730`. */ retentionInDays?: pulumi.Input; /** * The Secondary shared key for the Log Analytics Workspace. */ secondarySharedKey?: pulumi.Input; /** * Specifies the SKU of the Log Analytics Workspace. Possible values are `PerGB2018`, `PerNode`, `Premium`, `Standalone`, `Standard`, `CapacityReservation`, `LACluster` and `Unlimited`. Defaults to `PerGB2018`. * * > **Note:** `sku` should only be set to `LACluster` when the Log Analytics Workspace is linked to a Log Analytics Cluster. Additionally, `sku` cannot be modified while linked. * * > **Note:** Changing `sku` forces a new Log Analytics Workspace to be created, except when changing between `PerGB2018` and `CapacityReservation`. Changing `sku` to `CapacityReservation` or changing `reservationCapacityInGbPerDay` to a higher tier will lead to a 31-days commitment period, during which the SKU cannot be changed to a lower one. Please refer to [official documentation](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/cost-logs#commitment-tiers) for further information. * * > **Note:** A new pricing model took effect on `2018-04-03`, which requires the SKU `PerGB2018`. If you've provisioned resources before this date you have the option of remaining with the previous Pricing SKU and using the other SKUs defined above. More information about [the Pricing SKUs is available at the following URI](https://aka.ms/PricingTierWarning). */ sku?: pulumi.Input; /** * A mapping of tags to assign to the resource. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * The Workspace (or Customer) ID for the Log Analytics Workspace. */ workspaceId?: pulumi.Input; } /** * The set of arguments for constructing a AnalyticsWorkspace resource. */ export interface AnalyticsWorkspaceArgs { /** * Specifies if the log Analytics Workspace allows users accessing to data associated with the resources they have permission to view, without permission to workspace. Defaults to `true`. */ allowResourceOnlyPermissions?: pulumi.Input; /** * Is Customer Managed Storage mandatory for query management? */ cmkForQueryForced?: pulumi.Input; /** * The workspace daily quota for ingestion in GB. Defaults to `-1` (unlimited) if omitted. */ dailyQuotaGb?: pulumi.Input; /** * The ID of the Data Collection Rule to use for this workspace. */ dataCollectionRuleId?: pulumi.Input; /** * An `identity` block as defined below. */ identity?: pulumi.Input; /** * Whether to remove the data in the Log Analytics Workspace immediately after 30 days. */ immediateDataPurgeOn30DaysEnabled?: pulumi.Input; /** * Should the Log Analytics Workspace support ingestion over the Public Internet? Defaults to `true`. */ internetIngestionEnabled?: pulumi.Input; /** * Should the Log Analytics Workspace support querying over the Public Internet? Defaults to `true`. */ internetQueryEnabled?: pulumi.Input; /** * @deprecated `localAuthenticationDisabled` has been deprecated in favour of `localAuthenticationEnabled` and will be removed in v5.0 of the AzureRM Provider */ localAuthenticationDisabled?: pulumi.Input; /** * Specifies if the log Analytics workspace should allow local authentication methods in addition to Microsoft Entra (Azure AD). Defaults to `true`. */ localAuthenticationEnabled?: pulumi.Input; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ location?: pulumi.Input; /** * Specifies the name of the Log Analytics Workspace. Workspace name should include 4-63 letters, digits or '-'. The '-' shouldn't be the first or the last symbol. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * The capacity reservation level in GB for this workspace. Possible values are `100`, `200`, `300`, `400`, `500`, `1000`, `2000` and `5000`. * * > **Note:** `reservationCapacityInGbPerDay` can only be used when the `sku` is set to `CapacityReservation`. */ reservationCapacityInGbPerDay?: pulumi.Input; /** * The name of the resource group in which the Log Analytics workspace is created. Changing this forces a new resource to be created. */ resourceGroupName: pulumi.Input; /** * The workspace data retention in days. Possible values are between `30` and `730`. */ retentionInDays?: pulumi.Input; /** * Specifies the SKU of the Log Analytics Workspace. Possible values are `PerGB2018`, `PerNode`, `Premium`, `Standalone`, `Standard`, `CapacityReservation`, `LACluster` and `Unlimited`. Defaults to `PerGB2018`. * * > **Note:** `sku` should only be set to `LACluster` when the Log Analytics Workspace is linked to a Log Analytics Cluster. Additionally, `sku` cannot be modified while linked. * * > **Note:** Changing `sku` forces a new Log Analytics Workspace to be created, except when changing between `PerGB2018` and `CapacityReservation`. Changing `sku` to `CapacityReservation` or changing `reservationCapacityInGbPerDay` to a higher tier will lead to a 31-days commitment period, during which the SKU cannot be changed to a lower one. Please refer to [official documentation](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/cost-logs#commitment-tiers) for further information. * * > **Note:** A new pricing model took effect on `2018-04-03`, which requires the SKU `PerGB2018`. If you've provisioned resources before this date you have the option of remaining with the previous Pricing SKU and using the other SKUs defined above. More information about [the Pricing SKUs is available at the following URI](https://aka.ms/PricingTierWarning). */ sku?: pulumi.Input; /** * A mapping of tags to assign to the resource. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; }