We recommend using Azure Native.
azure.securitycenter.SubscriptionPricing
Explore with Pulumi AI
Manages the Pricing Tier for Azure Security Center in the current subscription.
NOTE: Deletion of this resource will reset the pricing tier to
Free
Example Usage
Basic usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = new Azure.SecurityCenter.SubscriptionPricing("example", new()
{
ResourceType = "VirtualMachines",
Tier = "Standard",
});
});
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/securitycenter"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := securitycenter.NewSubscriptionPricing(ctx, "example", &securitycenter.SubscriptionPricingArgs{
ResourceType: pulumi.String("VirtualMachines"),
Tier: pulumi.String("Standard"),
})
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.azure.securitycenter.SubscriptionPricing;
import com.pulumi.azure.securitycenter.SubscriptionPricingArgs;
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 example = new SubscriptionPricing("example", SubscriptionPricingArgs.builder()
.resourceType("VirtualMachines")
.tier("Standard")
.build());
}
}
import pulumi
import pulumi_azure as azure
example = azure.securitycenter.SubscriptionPricing("example",
resource_type="VirtualMachines",
tier="Standard")
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = new azure.securitycenter.SubscriptionPricing("example", {
resourceType: "VirtualMachines",
tier: "Standard",
});
resources:
example:
type: azure:securitycenter:SubscriptionPricing
properties:
resourceType: VirtualMachines
tier: Standard
Using Extensions with Defender CSPM
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example1 = new Azure.SecurityCenter.SubscriptionPricing("example1", new()
{
Extensions = new[]
{
new Azure.SecurityCenter.Inputs.SubscriptionPricingExtensionArgs
{
Name = "ContainerRegistriesVulnerabilityAssessments",
},
new Azure.SecurityCenter.Inputs.SubscriptionPricingExtensionArgs
{
AdditionalExtensionProperties =
{
{ "ExclusionTags", "[]" },
},
Name = "AgentlessVmScanning",
},
new Azure.SecurityCenter.Inputs.SubscriptionPricingExtensionArgs
{
Name = "AgentlessDiscoveryForKubernetes",
},
new Azure.SecurityCenter.Inputs.SubscriptionPricingExtensionArgs
{
Name = "SensitiveDataDiscovery",
},
},
ResourceType = "CloudPosture",
Tier = "Standard",
});
});
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/securitycenter"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := securitycenter.NewSubscriptionPricing(ctx, "example1", &securitycenter.SubscriptionPricingArgs{
Extensions: securitycenter.SubscriptionPricingExtensionArray{
&securitycenter.SubscriptionPricingExtensionArgs{
Name: pulumi.String("ContainerRegistriesVulnerabilityAssessments"),
},
&securitycenter.SubscriptionPricingExtensionArgs{
AdditionalExtensionProperties: pulumi.StringMap{
"ExclusionTags": pulumi.String("[]"),
},
Name: pulumi.String("AgentlessVmScanning"),
},
&securitycenter.SubscriptionPricingExtensionArgs{
Name: pulumi.String("AgentlessDiscoveryForKubernetes"),
},
&securitycenter.SubscriptionPricingExtensionArgs{
Name: pulumi.String("SensitiveDataDiscovery"),
},
},
ResourceType: pulumi.String("CloudPosture"),
Tier: pulumi.String("Standard"),
})
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.azure.securitycenter.SubscriptionPricing;
import com.pulumi.azure.securitycenter.SubscriptionPricingArgs;
import com.pulumi.azure.securitycenter.inputs.SubscriptionPricingExtensionArgs;
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 example1 = new SubscriptionPricing("example1", SubscriptionPricingArgs.builder()
.extensions(
SubscriptionPricingExtensionArgs.builder()
.name("ContainerRegistriesVulnerabilityAssessments")
.build(),
SubscriptionPricingExtensionArgs.builder()
.additionalExtensionProperties(Map.of("ExclusionTags", "[]"))
.name("AgentlessVmScanning")
.build(),
SubscriptionPricingExtensionArgs.builder()
.name("AgentlessDiscoveryForKubernetes")
.build(),
SubscriptionPricingExtensionArgs.builder()
.name("SensitiveDataDiscovery")
.build())
.resourceType("CloudPosture")
.tier("Standard")
.build());
}
}
import pulumi
import pulumi_azure as azure
example1 = azure.securitycenter.SubscriptionPricing("example1",
extensions=[
azure.securitycenter.SubscriptionPricingExtensionArgs(
name="ContainerRegistriesVulnerabilityAssessments",
),
azure.securitycenter.SubscriptionPricingExtensionArgs(
additional_extension_properties={
"ExclusionTags": "[]",
},
name="AgentlessVmScanning",
),
azure.securitycenter.SubscriptionPricingExtensionArgs(
name="AgentlessDiscoveryForKubernetes",
),
azure.securitycenter.SubscriptionPricingExtensionArgs(
name="SensitiveDataDiscovery",
),
],
resource_type="CloudPosture",
tier="Standard")
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example1 = new azure.securitycenter.SubscriptionPricing("example1", {
extensions: [
{
name: "ContainerRegistriesVulnerabilityAssessments",
},
{
additionalExtensionProperties: {
ExclusionTags: "[]",
},
name: "AgentlessVmScanning",
},
{
name: "AgentlessDiscoveryForKubernetes",
},
{
name: "SensitiveDataDiscovery",
},
],
resourceType: "CloudPosture",
tier: "Standard",
});
resources:
example1:
type: azure:securitycenter:SubscriptionPricing
properties:
extensions:
- name: ContainerRegistriesVulnerabilityAssessments
- additionalExtensionProperties:
ExclusionTags: '[]'
name: AgentlessVmScanning
- name: AgentlessDiscoveryForKubernetes
- name: SensitiveDataDiscovery
resourceType: CloudPosture
tier: Standard
Create SubscriptionPricing Resource
new SubscriptionPricing(name: string, args: SubscriptionPricingArgs, opts?: CustomResourceOptions);
@overload
def SubscriptionPricing(resource_name: str,
opts: Optional[ResourceOptions] = None,
extensions: Optional[Sequence[SubscriptionPricingExtensionArgs]] = None,
resource_type: Optional[str] = None,
subplan: Optional[str] = None,
tier: Optional[str] = None)
@overload
def SubscriptionPricing(resource_name: str,
args: SubscriptionPricingArgs,
opts: Optional[ResourceOptions] = None)
func NewSubscriptionPricing(ctx *Context, name string, args SubscriptionPricingArgs, opts ...ResourceOption) (*SubscriptionPricing, error)
public SubscriptionPricing(string name, SubscriptionPricingArgs args, CustomResourceOptions? opts = null)
public SubscriptionPricing(String name, SubscriptionPricingArgs args)
public SubscriptionPricing(String name, SubscriptionPricingArgs args, CustomResourceOptions options)
type: azure:securitycenter:SubscriptionPricing
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SubscriptionPricingArgs
- 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 SubscriptionPricingArgs
- 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 SubscriptionPricingArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SubscriptionPricingArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SubscriptionPricingArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
SubscriptionPricing Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The SubscriptionPricing resource accepts the following input properties:
- Tier string
The pricing tier to use. Possible values are
Free
andStandard
.- Extensions
List<Subscription
Pricing Extension> One or more
extension
blocks as defined below.- Resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- Subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- Tier string
The pricing tier to use. Possible values are
Free
andStandard
.- Extensions
[]Subscription
Pricing Extension Args One or more
extension
blocks as defined below.- Resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- Subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier String
The pricing tier to use. Possible values are
Free
andStandard
.- extensions
List<Subscription
Pricing Extension> One or more
extension
blocks as defined below.- resource
Type String The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan String
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier string
The pricing tier to use. Possible values are
Free
andStandard
.- extensions
Subscription
Pricing Extension[] One or more
extension
blocks as defined below.- resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier str
The pricing tier to use. Possible values are
Free
andStandard
.- extensions
Sequence[Subscription
Pricing Extension Args] One or more
extension
blocks as defined below.- resource_
type str The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan str
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier String
The pricing tier to use. Possible values are
Free
andStandard
.- extensions List<Property Map>
One or more
extension
blocks as defined below.- resource
Type String The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan String
Resource type pricing subplan. Contact your MSFT representative for possible values.
Outputs
All input properties are implicitly available as output properties. Additionally, the SubscriptionPricing resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Id string
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
- id string
The provider-assigned unique ID for this managed resource.
- id str
The provider-assigned unique ID for this managed resource.
- id String
The provider-assigned unique ID for this managed resource.
Look up Existing SubscriptionPricing Resource
Get an existing SubscriptionPricing resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: SubscriptionPricingState, opts?: CustomResourceOptions): SubscriptionPricing
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
extensions: Optional[Sequence[SubscriptionPricingExtensionArgs]] = None,
resource_type: Optional[str] = None,
subplan: Optional[str] = None,
tier: Optional[str] = None) -> SubscriptionPricing
func GetSubscriptionPricing(ctx *Context, name string, id IDInput, state *SubscriptionPricingState, opts ...ResourceOption) (*SubscriptionPricing, error)
public static SubscriptionPricing Get(string name, Input<string> id, SubscriptionPricingState? state, CustomResourceOptions? opts = null)
public static SubscriptionPricing get(String name, Output<String> id, SubscriptionPricingState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Extensions
List<Subscription
Pricing Extension> One or more
extension
blocks as defined below.- Resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- Subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- Tier string
The pricing tier to use. Possible values are
Free
andStandard
.
- Extensions
[]Subscription
Pricing Extension Args One or more
extension
blocks as defined below.- Resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- Subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- Tier string
The pricing tier to use. Possible values are
Free
andStandard
.
- extensions
List<Subscription
Pricing Extension> One or more
extension
blocks as defined below.- resource
Type String The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan String
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier String
The pricing tier to use. Possible values are
Free
andStandard
.
- extensions
Subscription
Pricing Extension[] One or more
extension
blocks as defined below.- resource
Type string The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan string
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier string
The pricing tier to use. Possible values are
Free
andStandard
.
- extensions
Sequence[Subscription
Pricing Extension Args] One or more
extension
blocks as defined below.- resource_
type str The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan str
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier str
The pricing tier to use. Possible values are
Free
andStandard
.
- extensions List<Property Map>
One or more
extension
blocks as defined below.- resource
Type String The resource type this setting affects. Possible values are
Api
,AppServices
,ContainerRegistry
,KeyVaults
,KubernetesService
,SqlServers
,SqlServerVirtualMachines
,StorageAccounts
,VirtualMachines
,Arm
,Dns
,OpenSourceRelationalDatabases
,Containers
,CosmosDbs
andCloudPosture
. Defaults toVirtualMachines
- subplan String
Resource type pricing subplan. Contact your MSFT representative for possible values.
- tier String
The pricing tier to use. Possible values are
Free
andStandard
.
Supporting Types
SubscriptionPricingExtension, SubscriptionPricingExtensionArgs
- Name string
The name of extension.
- Additional
Extension Dictionary<string, string>Properties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
- Name string
The name of extension.
- Additional
Extension map[string]stringProperties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
- name String
The name of extension.
- additional
Extension Map<String,String>Properties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
- name string
The name of extension.
- additional
Extension {[key: string]: string}Properties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
- name str
The name of extension.
- additional_
extension_ Mapping[str, str]properties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
- name String
The name of extension.
- additional
Extension Map<String>Properties Key/Value pairs that are required for some extensions.
NOTE: If an extension is not defined, it will not be enabled.
NOTE: Changing the pricing tier to
Standard
affects all resources of the given type in the subscription and could be quite costly.
Import
The pricing tier can be imported using the resource id
, e.g.
$ pulumi import azure:securitycenter/subscriptionPricing:SubscriptionPricing example /subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Security/pricings/<resource_type>
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
azurerm
Terraform Provider.