1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. ddos
  5. DomainResource
Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi

alicloud.ddos.DomainResource

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi

    Provides a Anti-DDoS Pro Domain Resource resource.

    For information about Anti-DDoS Pro Domain Resource and how to use it, see What is Domain Resource.

    NOTE: Available since v1.123.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "tf-example";
    const domain = config.get("domain") || "tf-example.alibaba.com";
    const defaultDdosCooInstance = new alicloud.ddos.DdosCooInstance("defaultDdosCooInstance", {
        bandwidth: "30",
        baseBandwidth: "30",
        serviceBandwidth: "100",
        portCount: "50",
        domainCount: "50",
        period: 1,
        productType: "ddoscoo",
    });
    const defaultDomainResource = new alicloud.ddos.DomainResource("defaultDomainResource", {
        domain: domain,
        rsType: 0,
        instanceIds: [defaultDdosCooInstance.id],
        realServers: ["177.167.32.11"],
        httpsExt: "{\"Http2\":1,\"Http2https\":0,\"Https2http\":0}",
        proxyTypes: [{
            proxyPorts: [443],
            proxyType: "https",
        }],
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "tf-example"
    domain = config.get("domain")
    if domain is None:
        domain = "tf-example.alibaba.com"
    default_ddos_coo_instance = alicloud.ddos.DdosCooInstance("defaultDdosCooInstance",
        bandwidth="30",
        base_bandwidth="30",
        service_bandwidth="100",
        port_count="50",
        domain_count="50",
        period=1,
        product_type="ddoscoo")
    default_domain_resource = alicloud.ddos.DomainResource("defaultDomainResource",
        domain=domain,
        rs_type=0,
        instance_ids=[default_ddos_coo_instance.id],
        real_servers=["177.167.32.11"],
        https_ext="{\"Http2\":1,\"Http2https\":0,\"Https2http\":0}",
        proxy_types=[alicloud.ddos.DomainResourceProxyTypeArgs(
            proxy_ports=[443],
            proxy_type="https",
        )])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ddos"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := "tf-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		domain := "tf-example.alibaba.com"
    		if param := cfg.Get("domain"); param != "" {
    			domain = param
    		}
    		defaultDdosCooInstance, err := ddos.NewDdosCooInstance(ctx, "defaultDdosCooInstance", &ddos.DdosCooInstanceArgs{
    			Bandwidth:        pulumi.String("30"),
    			BaseBandwidth:    pulumi.String("30"),
    			ServiceBandwidth: pulumi.String("100"),
    			PortCount:        pulumi.String("50"),
    			DomainCount:      pulumi.String("50"),
    			Period:           pulumi.Int(1),
    			ProductType:      pulumi.String("ddoscoo"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ddos.NewDomainResource(ctx, "defaultDomainResource", &ddos.DomainResourceArgs{
    			Domain: pulumi.String(domain),
    			RsType: pulumi.Int(0),
    			InstanceIds: pulumi.StringArray{
    				defaultDdosCooInstance.ID(),
    			},
    			RealServers: pulumi.StringArray{
    				pulumi.String("177.167.32.11"),
    			},
    			HttpsExt: pulumi.String("{\"Http2\":1,\"Http2https\":0,\"Https2http\":0}"),
    			ProxyTypes: ddos.DomainResourceProxyTypeArray{
    				&ddos.DomainResourceProxyTypeArgs{
    					ProxyPorts: pulumi.IntArray{
    						pulumi.Int(443),
    					},
    					ProxyType: pulumi.String("https"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "tf-example";
        var domain = config.Get("domain") ?? "tf-example.alibaba.com";
        var defaultDdosCooInstance = new AliCloud.Ddos.DdosCooInstance("defaultDdosCooInstance", new()
        {
            Bandwidth = "30",
            BaseBandwidth = "30",
            ServiceBandwidth = "100",
            PortCount = "50",
            DomainCount = "50",
            Period = 1,
            ProductType = "ddoscoo",
        });
    
        var defaultDomainResource = new AliCloud.Ddos.DomainResource("defaultDomainResource", new()
        {
            Domain = domain,
            RsType = 0,
            InstanceIds = new[]
            {
                defaultDdosCooInstance.Id,
            },
            RealServers = new[]
            {
                "177.167.32.11",
            },
            HttpsExt = "{\"Http2\":1,\"Http2https\":0,\"Https2http\":0}",
            ProxyTypes = new[]
            {
                new AliCloud.Ddos.Inputs.DomainResourceProxyTypeArgs
                {
                    ProxyPorts = new[]
                    {
                        443,
                    },
                    ProxyType = "https",
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.ddos.DdosCooInstance;
    import com.pulumi.alicloud.ddos.DdosCooInstanceArgs;
    import com.pulumi.alicloud.ddos.DomainResource;
    import com.pulumi.alicloud.ddos.DomainResourceArgs;
    import com.pulumi.alicloud.ddos.inputs.DomainResourceProxyTypeArgs;
    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) {
            final var config = ctx.config();
            final var name = config.get("name").orElse("tf-example");
            final var domain = config.get("domain").orElse("tf-example.alibaba.com");
            var defaultDdosCooInstance = new DdosCooInstance("defaultDdosCooInstance", DdosCooInstanceArgs.builder()        
                .bandwidth("30")
                .baseBandwidth("30")
                .serviceBandwidth("100")
                .portCount("50")
                .domainCount("50")
                .period("1")
                .productType("ddoscoo")
                .build());
    
            var defaultDomainResource = new DomainResource("defaultDomainResource", DomainResourceArgs.builder()        
                .domain(domain)
                .rsType(0)
                .instanceIds(defaultDdosCooInstance.id())
                .realServers("177.167.32.11")
                .httpsExt("{\"Http2\":1,\"Http2https\":0,\"Https2http\":0}")
                .proxyTypes(DomainResourceProxyTypeArgs.builder()
                    .proxyPorts(443)
                    .proxyType("https")
                    .build())
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: tf-example
      domain:
        type: string
        default: tf-example.alibaba.com
    resources:
      defaultDdosCooInstance:
        type: alicloud:ddos:DdosCooInstance
        properties:
          bandwidth: '30'
          baseBandwidth: '30'
          serviceBandwidth: '100'
          portCount: '50'
          domainCount: '50'
          period: '1'
          productType: ddoscoo
      defaultDomainResource:
        type: alicloud:ddos:DomainResource
        properties:
          domain: ${domain}
          rsType: 0
          instanceIds:
            - ${defaultDdosCooInstance.id}
          realServers:
            - 177.167.32.11
          httpsExt: '{"Http2":1,"Http2https":0,"Https2http":0}'
          proxyTypes:
            - proxyPorts:
                - 443
              proxyType: https
    

    Create DomainResource Resource

    new DomainResource(name: string, args: DomainResourceArgs, opts?: CustomResourceOptions);
    @overload
    def DomainResource(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       domain: Optional[str] = None,
                       https_ext: Optional[str] = None,
                       instance_ids: Optional[Sequence[str]] = None,
                       ocsp_enabled: Optional[bool] = None,
                       proxy_types: Optional[Sequence[DomainResourceProxyTypeArgs]] = None,
                       real_servers: Optional[Sequence[str]] = None,
                       rs_type: Optional[int] = None)
    @overload
    def DomainResource(resource_name: str,
                       args: DomainResourceArgs,
                       opts: Optional[ResourceOptions] = None)
    func NewDomainResource(ctx *Context, name string, args DomainResourceArgs, opts ...ResourceOption) (*DomainResource, error)
    public DomainResource(string name, DomainResourceArgs args, CustomResourceOptions? opts = null)
    public DomainResource(String name, DomainResourceArgs args)
    public DomainResource(String name, DomainResourceArgs args, CustomResourceOptions options)
    
    type: alicloud:ddos:DomainResource
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args DomainResourceArgs
    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 DomainResourceArgs
    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 DomainResourceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DomainResourceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DomainResourceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    DomainResource 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 DomainResource resource accepts the following input properties:

    Domain string
    The domain name of the website that you want to add to the instance.
    InstanceIds List<string>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ProxyTypes List<Pulumi.AliCloud.Ddos.Inputs.DomainResourceProxyType>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    RealServers List<string>
    the IP address. This field is required and must be a string array.
    RsType int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    HttpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    OcspEnabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    Domain string
    The domain name of the website that you want to add to the instance.
    InstanceIds []string

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ProxyTypes []DomainResourceProxyTypeArgs

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    RealServers []string
    the IP address. This field is required and must be a string array.
    RsType int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    HttpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    OcspEnabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    domain String
    The domain name of the website that you want to add to the instance.
    instanceIds List<String>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    proxyTypes List<DomainResourceProxyType>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers List<String>
    the IP address. This field is required and must be a string array.
    rsType Integer
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    httpsExt String
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    ocspEnabled Boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    domain string
    The domain name of the website that you want to add to the instance.
    instanceIds string[]

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    proxyTypes DomainResourceProxyType[]

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers string[]
    the IP address. This field is required and must be a string array.
    rsType number
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    httpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    ocspEnabled boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    domain str
    The domain name of the website that you want to add to the instance.
    instance_ids Sequence[str]

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    proxy_types Sequence[DomainResourceProxyTypeArgs]

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    real_servers Sequence[str]
    the IP address. This field is required and must be a string array.
    rs_type int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    https_ext str
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    ocsp_enabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    domain String
    The domain name of the website that you want to add to the instance.
    instanceIds List<String>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    proxyTypes List<Property Map>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers List<String>
    the IP address. This field is required and must be a string array.
    rsType Number
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    httpsExt String
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    ocspEnabled Boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:

    Outputs

    All input properties are implicitly available as output properties. Additionally, the DomainResource resource produces the following output properties:

    Cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    Id string
    The provider-assigned unique ID for this managed resource.
    Cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    Id string
    The provider-assigned unique ID for this managed resource.
    cname String
    (Available since v1.207.2) The CNAME assigned to the domain name.
    id String
    The provider-assigned unique ID for this managed resource.
    cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    id string
    The provider-assigned unique ID for this managed resource.
    cname str
    (Available since v1.207.2) The CNAME assigned to the domain name.
    id str
    The provider-assigned unique ID for this managed resource.
    cname String
    (Available since v1.207.2) The CNAME assigned to the domain name.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing DomainResource Resource

    Get an existing DomainResource 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?: DomainResourceState, opts?: CustomResourceOptions): DomainResource
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cname: Optional[str] = None,
            domain: Optional[str] = None,
            https_ext: Optional[str] = None,
            instance_ids: Optional[Sequence[str]] = None,
            ocsp_enabled: Optional[bool] = None,
            proxy_types: Optional[Sequence[DomainResourceProxyTypeArgs]] = None,
            real_servers: Optional[Sequence[str]] = None,
            rs_type: Optional[int] = None) -> DomainResource
    func GetDomainResource(ctx *Context, name string, id IDInput, state *DomainResourceState, opts ...ResourceOption) (*DomainResource, error)
    public static DomainResource Get(string name, Input<string> id, DomainResourceState? state, CustomResourceOptions? opts = null)
    public static DomainResource get(String name, Output<String> id, DomainResourceState 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.
    The following state arguments are supported:
    Cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    Domain string
    The domain name of the website that you want to add to the instance.
    HttpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    InstanceIds List<string>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    OcspEnabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    ProxyTypes List<Pulumi.AliCloud.Ddos.Inputs.DomainResourceProxyType>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    RealServers List<string>
    the IP address. This field is required and must be a string array.
    RsType int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    Cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    Domain string
    The domain name of the website that you want to add to the instance.
    HttpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    InstanceIds []string

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    OcspEnabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    ProxyTypes []DomainResourceProxyTypeArgs

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    RealServers []string
    the IP address. This field is required and must be a string array.
    RsType int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    cname String
    (Available since v1.207.2) The CNAME assigned to the domain name.
    domain String
    The domain name of the website that you want to add to the instance.
    httpsExt String
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    instanceIds List<String>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ocspEnabled Boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    proxyTypes List<DomainResourceProxyType>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers List<String>
    the IP address. This field is required and must be a string array.
    rsType Integer
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    cname string
    (Available since v1.207.2) The CNAME assigned to the domain name.
    domain string
    The domain name of the website that you want to add to the instance.
    httpsExt string
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    instanceIds string[]

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ocspEnabled boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    proxyTypes DomainResourceProxyType[]

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers string[]
    the IP address. This field is required and must be a string array.
    rsType number
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    cname str
    (Available since v1.207.2) The CNAME assigned to the domain name.
    domain str
    The domain name of the website that you want to add to the instance.
    https_ext str
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    instance_ids Sequence[str]

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ocsp_enabled bool
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    proxy_types Sequence[DomainResourceProxyTypeArgs]

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    real_servers Sequence[str]
    the IP address. This field is required and must be a string array.
    rs_type int
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:
    cname String
    (Available since v1.207.2) The CNAME assigned to the domain name.
    domain String
    The domain name of the website that you want to add to the instance.
    httpsExt String
    The advanced HTTPS settings. This parameter takes effect only when the value of ProxyType includes https. This parameter is a string that contains a JSON struct. The JSON struct includes the following fields:
    instanceIds List<String>

    A list of instance ID that you want to associate. If this parameter is empty, only the domain name of the website is added but no instance is associated with the website.

    NOTE: There is a potential diff error because of the order of instance_ids values indefinite. So, from version 1.161.0, instance_ids type has been updated as set from list, and you can use tolist to convert it to a list.

    ocspEnabled Boolean
    Specifies whether to enable the OCSP feature. Default value: false. Valid values:
    proxyTypes List<Property Map>

    Protocol type and port number information. See proxy_types below.

    NOTE: From version 1.206.0, proxy_types can be modified.

    realServers List<String>
    the IP address. This field is required and must be a string array.
    rsType Number
    The address type of the origin server. Use the domain name of the origin server if you deploy proxies, such as Web Application Firewall (WAF), between the origin server and the Anti-DDoS Pro or Anti-DDoS Premium instance. If you use the domain name, you must enter the address of the proxy, such as the CNAME of WAF. Valid values:

    Supporting Types

    DomainResourceProxyType, DomainResourceProxyTypeArgs

    ProxyPorts List<int>
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    ProxyType string
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.
    ProxyPorts []int
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    ProxyType string
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.
    proxyPorts List<Integer>
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    proxyType String
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.
    proxyPorts number[]
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    proxyType string
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.
    proxy_ports Sequence[int]
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    proxy_type str
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.
    proxyPorts List<Number>
    the port number. This field is required and must be an integer. NOTE: From version 1.206.0, proxy_ports can be modified.
    proxyType String
    the protocol type. This field is required and must be a string. Valid values: http, https, websocket, and websockets.

    Import

    Anti-DDoS Pro Domain Resource can be imported using the id, e.g.

    $ pulumi import alicloud:ddos/domainResource:DomainResource example <domain>
    

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi