QueueServiceProperties
The properties of a storage account’s Queue service. Latest API Version: 2019-06-01.
Example Usage
QueueServicesPut
using Pulumi;
using AzureNextGen = Pulumi.AzureNextGen;
class MyStack : Stack
{
public MyStack()
{
var queueServiceProperties = new AzureNextGen.Storage.Latest.QueueServiceProperties("queueServiceProperties", new AzureNextGen.Storage.Latest.QueueServicePropertiesArgs
{
AccountName = "sto8607",
Cors = new AzureNextGen.Storage.Latest.Inputs.CorsRulesArgs
{
CorsRules =
{
new AzureNextGen.Storage.Latest.Inputs.CorsRuleArgs
{
AllowedHeaders =
{
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
},
AllowedMethods =
{
"GET",
"HEAD",
"POST",
"OPTIONS",
"MERGE",
"PUT",
},
AllowedOrigins =
{
"http://www.contoso.com",
"http://www.fabrikam.com",
},
ExposedHeaders =
{
"x-ms-meta-*",
},
MaxAgeInSeconds = 100,
},
new AzureNextGen.Storage.Latest.Inputs.CorsRuleArgs
{
AllowedHeaders =
{
"*",
},
AllowedMethods =
{
"GET",
},
AllowedOrigins =
{
"*",
},
ExposedHeaders =
{
"*",
},
MaxAgeInSeconds = 2,
},
new AzureNextGen.Storage.Latest.Inputs.CorsRuleArgs
{
AllowedHeaders =
{
"x-ms-meta-12345675754564*",
},
AllowedMethods =
{
"GET",
"PUT",
},
AllowedOrigins =
{
"http://www.abc23.com",
"https://www.fabrikam.com/*",
},
ExposedHeaders =
{
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
},
MaxAgeInSeconds = 2000,
},
},
},
QueueServiceName = "default",
ResourceGroupName = "res4410",
});
}
}
package main
import (
storage "github.com/pulumi/pulumi-azure-nextgen/sdk/go/azure/storage/latest"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := storage.NewQueueServiceProperties(ctx, "queueServiceProperties", &storage.QueueServicePropertiesArgs{
AccountName: pulumi.String("sto8607"),
Cors: &storage.CorsRulesArgs{
CorsRules: storage.CorsRuleArray{
&storage.CorsRuleArgs{
AllowedHeaders: pulumi.StringArray{
pulumi.String("x-ms-meta-abc"),
pulumi.String("x-ms-meta-data*"),
pulumi.String("x-ms-meta-target*"),
},
AllowedMethods: pulumi.StringArray{
pulumi.String("GET"),
pulumi.String("HEAD"),
pulumi.String("POST"),
pulumi.String("OPTIONS"),
pulumi.String("MERGE"),
pulumi.String("PUT"),
},
AllowedOrigins: pulumi.StringArray{
pulumi.String("http://www.contoso.com"),
pulumi.String("http://www.fabrikam.com"),
},
ExposedHeaders: pulumi.StringArray{
pulumi.String("x-ms-meta-*"),
},
MaxAgeInSeconds: pulumi.Int(100),
},
&storage.CorsRuleArgs{
AllowedHeaders: pulumi.StringArray{
pulumi.String("*"),
},
AllowedMethods: pulumi.StringArray{
pulumi.String("GET"),
},
AllowedOrigins: pulumi.StringArray{
pulumi.String("*"),
},
ExposedHeaders: pulumi.StringArray{
pulumi.String("*"),
},
MaxAgeInSeconds: pulumi.Int(2),
},
&storage.CorsRuleArgs{
AllowedHeaders: pulumi.StringArray{
pulumi.String("x-ms-meta-12345675754564*"),
},
AllowedMethods: pulumi.StringArray{
pulumi.String("GET"),
pulumi.String("PUT"),
},
AllowedOrigins: pulumi.StringArray{
pulumi.String("http://www.abc23.com"),
pulumi.String("https://www.fabrikam.com/*"),
},
ExposedHeaders: pulumi.StringArray{
pulumi.String("x-ms-meta-abc"),
pulumi.String("x-ms-meta-data*"),
pulumi.String("x-ms-meta-target*"),
},
MaxAgeInSeconds: pulumi.Int(2000),
},
},
},
QueueServiceName: pulumi.String("default"),
ResourceGroupName: pulumi.String("res4410"),
})
if err != nil {
return err
}
return nil
})
}
import pulumi
import pulumi_azure_nextgen as azure_nextgen
queue_service_properties = azure_nextgen.storage.latest.QueueServiceProperties("queueServiceProperties",
account_name="sto8607",
cors=azure_nextgen.storage.latest.CorsRulesArgs(
cors_rules=[
azure_nextgen.storage.latest.CorsRuleArgs(
allowed_headers=[
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
],
allowed_methods=[
"GET",
"HEAD",
"POST",
"OPTIONS",
"MERGE",
"PUT",
],
allowed_origins=[
"http://www.contoso.com",
"http://www.fabrikam.com",
],
exposed_headers=["x-ms-meta-*"],
max_age_in_seconds=100,
),
azure_nextgen.storage.latest.CorsRuleArgs(
allowed_headers=["*"],
allowed_methods=["GET"],
allowed_origins=["*"],
exposed_headers=["*"],
max_age_in_seconds=2,
),
azure_nextgen.storage.latest.CorsRuleArgs(
allowed_headers=["x-ms-meta-12345675754564*"],
allowed_methods=[
"GET",
"PUT",
],
allowed_origins=[
"http://www.abc23.com",
"https://www.fabrikam.com/*",
],
exposed_headers=[
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
],
max_age_in_seconds=2000,
),
],
),
queue_service_name="default",
resource_group_name="res4410")
import * as pulumi from "@pulumi/pulumi";
import * as azure_nextgen from "@pulumi/azure-nextgen";
const queueServiceProperties = new azure_nextgen.storage.latest.QueueServiceProperties("queueServiceProperties", {
accountName: "sto8607",
cors: {
corsRules: [
{
allowedHeaders: [
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
],
allowedMethods: [
"GET",
"HEAD",
"POST",
"OPTIONS",
"MERGE",
"PUT",
],
allowedOrigins: [
"http://www.contoso.com",
"http://www.fabrikam.com",
],
exposedHeaders: ["x-ms-meta-*"],
maxAgeInSeconds: 100,
},
{
allowedHeaders: ["*"],
allowedMethods: ["GET"],
allowedOrigins: ["*"],
exposedHeaders: ["*"],
maxAgeInSeconds: 2,
},
{
allowedHeaders: ["x-ms-meta-12345675754564*"],
allowedMethods: [
"GET",
"PUT",
],
allowedOrigins: [
"http://www.abc23.com",
"https://www.fabrikam.com/*",
],
exposedHeaders: [
"x-ms-meta-abc",
"x-ms-meta-data*",
"x-ms-meta-target*",
],
maxAgeInSeconds: 2000,
},
],
},
queueServiceName: "default",
resourceGroupName: "res4410",
});
Create a QueueServiceProperties Resource
new QueueServiceProperties(name: string, args: QueueServicePropertiesArgs, opts?: CustomResourceOptions);
def QueueServiceProperties(resource_name: str, opts: Optional[ResourceOptions] = None, account_name: Optional[str] = None, cors: Optional[CorsRulesArgs] = None, queue_service_name: Optional[str] = None, resource_group_name: Optional[str] = None)
func NewQueueServiceProperties(ctx *Context, name string, args QueueServicePropertiesArgs, opts ...ResourceOption) (*QueueServiceProperties, error)
public QueueServiceProperties(string name, QueueServicePropertiesArgs args, CustomResourceOptions? opts = null)
- name string
- The unique name of the resource.
- args QueueServicePropertiesArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args QueueServicePropertiesArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args QueueServicePropertiesArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
QueueServiceProperties Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The QueueServiceProperties resource accepts the following input properties:
- Account
Name string - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only.
- Queue
Service stringName - The name of the Queue Service within the specified storage account. Queue Service Name must be ‘default’
- Resource
Group stringName - The name of the resource group within the user’s subscription. The name is case insensitive.
- Cors
Pulumi.
Azure Next Gen. Storage. Inputs. Cors Rules Args - Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule elements are included in the request body, all CORS rules will be deleted, and CORS will be disabled for the Queue service.
- Account
Name string - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only.
- Queue
Service stringName - The name of the Queue Service within the specified storage account. Queue Service Name must be ‘default’
- Resource
Group stringName - The name of the resource group within the user’s subscription. The name is case insensitive.
- Cors
Cors
Rules - Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule elements are included in the request body, all CORS rules will be deleted, and CORS will be disabled for the Queue service.
- account
Name string - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only.
- queue
Service stringName - The name of the Queue Service within the specified storage account. Queue Service Name must be ‘default’
- resource
Group stringName - The name of the resource group within the user’s subscription. The name is case insensitive.
- cors
Cors
Rules - Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule elements are included in the request body, all CORS rules will be deleted, and CORS will be disabled for the Queue service.
- account_
name str - The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only.
- queue_
service_ strname - The name of the Queue Service within the specified storage account. Queue Service Name must be ‘default’
- resource_
group_ strname - The name of the resource group within the user’s subscription. The name is case insensitive.
- cors
Cors
Rules Args - Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule elements are included in the request body, all CORS rules will be deleted, and CORS will be disabled for the Queue service.
Outputs
All input properties are implicitly available as output properties. Additionally, the QueueServiceProperties resource produces the following output properties:
Supporting Types
CorsRule
- Allowed
Headers List<string> - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- Allowed
Methods List<string> - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- Allowed
Origins List<string> - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- Exposed
Headers List<string> - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- Max
Age intIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- Allowed
Headers []string - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- Allowed
Methods []string - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- Allowed
Origins []string - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- Exposed
Headers []string - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- Max
Age intIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- allowed
Headers string[] - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- allowed
Methods string[] - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- allowed
Origins string[] - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- exposed
Headers string[] - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- max
Age numberIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- allowed_
headers Sequence[str] - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- allowed_
methods Sequence[str] - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- allowed_
origins Sequence[str] - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- exposed_
headers Sequence[str] - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- max_
age_ intin_ seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
CorsRuleResponse
- Allowed
Headers List<string> - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- Allowed
Methods List<string> - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- Allowed
Origins List<string> - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- Exposed
Headers List<string> - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- Max
Age intIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- Allowed
Headers []string - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- Allowed
Methods []string - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- Allowed
Origins []string - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- Exposed
Headers []string - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- Max
Age intIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- allowed
Headers string[] - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- allowed
Methods string[] - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- allowed
Origins string[] - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- exposed
Headers string[] - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- max
Age numberIn Seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
- allowed_
headers Sequence[str] - Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.
- allowed_
methods Sequence[str] - Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.
- allowed_
origins Sequence[str] - Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or “*” to allow all domains
- exposed_
headers Sequence[str] - Required if CorsRule element is present. A list of response headers to expose to CORS clients.
- max_
age_ intin_ seconds - Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.
CorsRules
- Cors
Rules List<Pulumi.Azure Next Gen. Storage. Inputs. Cors Rule Args> - The List of CORS rules. You can include up to five CorsRule elements in the request.
- Cors
Rules []CorsRule - The List of CORS rules. You can include up to five CorsRule elements in the request.
- cors
Rules CorsRule[] - The List of CORS rules. You can include up to five CorsRule elements in the request.
- cors_
rules Sequence[CorsRule Args] - The List of CORS rules. You can include up to five CorsRule elements in the request.
CorsRulesResponse
- Cors
Rules List<Pulumi.Azure Next Gen. Storage. Inputs. Cors Rule Response Args> - The List of CORS rules. You can include up to five CorsRule elements in the request.
- Cors
Rules []CorsRule Response - The List of CORS rules. You can include up to five CorsRule elements in the request.
- cors
Rules CorsRule Response[] - The List of CORS rules. You can include up to five CorsRule elements in the request.
- cors_
rules Sequence[CorsRule Response Args] - The List of CORS rules. You can include up to five CorsRule elements in the request.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-nextgen:storage/latest:QueueServiceProperties default /subscriptions/{subscription-id}/resourceGroups/res4410/providers/Microsoft.Storage/storageAccounts/sto8607/queueServices/default
Package Details
- Repository
- https://github.com/pulumi/pulumi-azure-nextgen
- License
- Apache-2.0