1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. compute
  5. RegionTargetHttpProxy
Google Cloud Classic v7.16.0 published on Wednesday, Mar 27, 2024 by Pulumi

gcp.compute.RegionTargetHttpProxy

Explore with Pulumi AI

gcp logo
Google Cloud Classic v7.16.0 published on Wednesday, Mar 27, 2024 by Pulumi

    Represents a RegionTargetHttpProxy resource, which is used by one or more forwarding rules to route incoming HTTP requests to a URL map.

    To get more information about RegionTargetHttpProxy, see:

    Example Usage

    Region Target Http Proxy Basic

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const defaultRegionHealthCheck = new gcp.compute.RegionHealthCheck("default", {
        region: "us-central1",
        name: "http-health-check",
        httpHealthCheck: {
            port: 80,
        },
    });
    const defaultRegionBackendService = new gcp.compute.RegionBackendService("default", {
        region: "us-central1",
        name: "backend-service",
        protocol: "HTTP",
        timeoutSec: 10,
        loadBalancingScheme: "INTERNAL_MANAGED",
        healthChecks: defaultRegionHealthCheck.id,
    });
    const defaultRegionUrlMap = new gcp.compute.RegionUrlMap("default", {
        region: "us-central1",
        name: "url-map",
        defaultService: defaultRegionBackendService.id,
        hostRules: [{
            hosts: ["mysite.com"],
            pathMatcher: "allpaths",
        }],
        pathMatchers: [{
            name: "allpaths",
            defaultService: defaultRegionBackendService.id,
            pathRules: [{
                paths: ["/*"],
                service: defaultRegionBackendService.id,
            }],
        }],
    });
    const _default = new gcp.compute.RegionTargetHttpProxy("default", {
        region: "us-central1",
        name: "test-proxy",
        urlMap: defaultRegionUrlMap.id,
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default_region_health_check = gcp.compute.RegionHealthCheck("default",
        region="us-central1",
        name="http-health-check",
        http_health_check=gcp.compute.RegionHealthCheckHttpHealthCheckArgs(
            port=80,
        ))
    default_region_backend_service = gcp.compute.RegionBackendService("default",
        region="us-central1",
        name="backend-service",
        protocol="HTTP",
        timeout_sec=10,
        load_balancing_scheme="INTERNAL_MANAGED",
        health_checks=default_region_health_check.id)
    default_region_url_map = gcp.compute.RegionUrlMap("default",
        region="us-central1",
        name="url-map",
        default_service=default_region_backend_service.id,
        host_rules=[gcp.compute.RegionUrlMapHostRuleArgs(
            hosts=["mysite.com"],
            path_matcher="allpaths",
        )],
        path_matchers=[gcp.compute.RegionUrlMapPathMatcherArgs(
            name="allpaths",
            default_service=default_region_backend_service.id,
            path_rules=[gcp.compute.RegionUrlMapPathMatcherPathRuleArgs(
                paths=["/*"],
                service=default_region_backend_service.id,
            )],
        )])
    default = gcp.compute.RegionTargetHttpProxy("default",
        region="us-central1",
        name="test-proxy",
        url_map=default_region_url_map.id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/compute"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		defaultRegionHealthCheck, err := compute.NewRegionHealthCheck(ctx, "default", &compute.RegionHealthCheckArgs{
    			Region: pulumi.String("us-central1"),
    			Name:   pulumi.String("http-health-check"),
    			HttpHealthCheck: &compute.RegionHealthCheckHttpHealthCheckArgs{
    				Port: pulumi.Int(80),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		defaultRegionBackendService, err := compute.NewRegionBackendService(ctx, "default", &compute.RegionBackendServiceArgs{
    			Region:              pulumi.String("us-central1"),
    			Name:                pulumi.String("backend-service"),
    			Protocol:            pulumi.String("HTTP"),
    			TimeoutSec:          pulumi.Int(10),
    			LoadBalancingScheme: pulumi.String("INTERNAL_MANAGED"),
    			HealthChecks:        defaultRegionHealthCheck.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		defaultRegionUrlMap, err := compute.NewRegionUrlMap(ctx, "default", &compute.RegionUrlMapArgs{
    			Region:         pulumi.String("us-central1"),
    			Name:           pulumi.String("url-map"),
    			DefaultService: defaultRegionBackendService.ID(),
    			HostRules: compute.RegionUrlMapHostRuleArray{
    				&compute.RegionUrlMapHostRuleArgs{
    					Hosts: pulumi.StringArray{
    						pulumi.String("mysite.com"),
    					},
    					PathMatcher: pulumi.String("allpaths"),
    				},
    			},
    			PathMatchers: compute.RegionUrlMapPathMatcherArray{
    				&compute.RegionUrlMapPathMatcherArgs{
    					Name:           pulumi.String("allpaths"),
    					DefaultService: defaultRegionBackendService.ID(),
    					PathRules: compute.RegionUrlMapPathMatcherPathRuleArray{
    						&compute.RegionUrlMapPathMatcherPathRuleArgs{
    							Paths: pulumi.StringArray{
    								pulumi.String("/*"),
    							},
    							Service: defaultRegionBackendService.ID(),
    						},
    					},
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = compute.NewRegionTargetHttpProxy(ctx, "default", &compute.RegionTargetHttpProxyArgs{
    			Region: pulumi.String("us-central1"),
    			Name:   pulumi.String("test-proxy"),
    			UrlMap: defaultRegionUrlMap.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var defaultRegionHealthCheck = new Gcp.Compute.RegionHealthCheck("default", new()
        {
            Region = "us-central1",
            Name = "http-health-check",
            HttpHealthCheck = new Gcp.Compute.Inputs.RegionHealthCheckHttpHealthCheckArgs
            {
                Port = 80,
            },
        });
    
        var defaultRegionBackendService = new Gcp.Compute.RegionBackendService("default", new()
        {
            Region = "us-central1",
            Name = "backend-service",
            Protocol = "HTTP",
            TimeoutSec = 10,
            LoadBalancingScheme = "INTERNAL_MANAGED",
            HealthChecks = defaultRegionHealthCheck.Id,
        });
    
        var defaultRegionUrlMap = new Gcp.Compute.RegionUrlMap("default", new()
        {
            Region = "us-central1",
            Name = "url-map",
            DefaultService = defaultRegionBackendService.Id,
            HostRules = new[]
            {
                new Gcp.Compute.Inputs.RegionUrlMapHostRuleArgs
                {
                    Hosts = new[]
                    {
                        "mysite.com",
                    },
                    PathMatcher = "allpaths",
                },
            },
            PathMatchers = new[]
            {
                new Gcp.Compute.Inputs.RegionUrlMapPathMatcherArgs
                {
                    Name = "allpaths",
                    DefaultService = defaultRegionBackendService.Id,
                    PathRules = new[]
                    {
                        new Gcp.Compute.Inputs.RegionUrlMapPathMatcherPathRuleArgs
                        {
                            Paths = new[]
                            {
                                "/*",
                            },
                            Service = defaultRegionBackendService.Id,
                        },
                    },
                },
            },
        });
    
        var @default = new Gcp.Compute.RegionTargetHttpProxy("default", new()
        {
            Region = "us-central1",
            Name = "test-proxy",
            UrlMap = defaultRegionUrlMap.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.compute.RegionHealthCheck;
    import com.pulumi.gcp.compute.RegionHealthCheckArgs;
    import com.pulumi.gcp.compute.inputs.RegionHealthCheckHttpHealthCheckArgs;
    import com.pulumi.gcp.compute.RegionBackendService;
    import com.pulumi.gcp.compute.RegionBackendServiceArgs;
    import com.pulumi.gcp.compute.RegionUrlMap;
    import com.pulumi.gcp.compute.RegionUrlMapArgs;
    import com.pulumi.gcp.compute.inputs.RegionUrlMapHostRuleArgs;
    import com.pulumi.gcp.compute.inputs.RegionUrlMapPathMatcherArgs;
    import com.pulumi.gcp.compute.RegionTargetHttpProxy;
    import com.pulumi.gcp.compute.RegionTargetHttpProxyArgs;
    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 defaultRegionHealthCheck = new RegionHealthCheck("defaultRegionHealthCheck", RegionHealthCheckArgs.builder()        
                .region("us-central1")
                .name("http-health-check")
                .httpHealthCheck(RegionHealthCheckHttpHealthCheckArgs.builder()
                    .port(80)
                    .build())
                .build());
    
            var defaultRegionBackendService = new RegionBackendService("defaultRegionBackendService", RegionBackendServiceArgs.builder()        
                .region("us-central1")
                .name("backend-service")
                .protocol("HTTP")
                .timeoutSec(10)
                .loadBalancingScheme("INTERNAL_MANAGED")
                .healthChecks(defaultRegionHealthCheck.id())
                .build());
    
            var defaultRegionUrlMap = new RegionUrlMap("defaultRegionUrlMap", RegionUrlMapArgs.builder()        
                .region("us-central1")
                .name("url-map")
                .defaultService(defaultRegionBackendService.id())
                .hostRules(RegionUrlMapHostRuleArgs.builder()
                    .hosts("mysite.com")
                    .pathMatcher("allpaths")
                    .build())
                .pathMatchers(RegionUrlMapPathMatcherArgs.builder()
                    .name("allpaths")
                    .defaultService(defaultRegionBackendService.id())
                    .pathRules(RegionUrlMapPathMatcherPathRuleArgs.builder()
                        .paths("/*")
                        .service(defaultRegionBackendService.id())
                        .build())
                    .build())
                .build());
    
            var default_ = new RegionTargetHttpProxy("default", RegionTargetHttpProxyArgs.builder()        
                .region("us-central1")
                .name("test-proxy")
                .urlMap(defaultRegionUrlMap.id())
                .build());
    
        }
    }
    
    resources:
      default:
        type: gcp:compute:RegionTargetHttpProxy
        properties:
          region: us-central1
          name: test-proxy
          urlMap: ${defaultRegionUrlMap.id}
      defaultRegionUrlMap:
        type: gcp:compute:RegionUrlMap
        name: default
        properties:
          region: us-central1
          name: url-map
          defaultService: ${defaultRegionBackendService.id}
          hostRules:
            - hosts:
                - mysite.com
              pathMatcher: allpaths
          pathMatchers:
            - name: allpaths
              defaultService: ${defaultRegionBackendService.id}
              pathRules:
                - paths:
                    - /*
                  service: ${defaultRegionBackendService.id}
      defaultRegionBackendService:
        type: gcp:compute:RegionBackendService
        name: default
        properties:
          region: us-central1
          name: backend-service
          protocol: HTTP
          timeoutSec: 10
          loadBalancingScheme: INTERNAL_MANAGED
          healthChecks: ${defaultRegionHealthCheck.id}
      defaultRegionHealthCheck:
        type: gcp:compute:RegionHealthCheck
        name: default
        properties:
          region: us-central1
          name: http-health-check
          httpHealthCheck:
            port: 80
    

    Region Target Http Proxy Https Redirect

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const defaultRegionUrlMap = new gcp.compute.RegionUrlMap("default", {
        region: "us-central1",
        name: "url-map",
        defaultUrlRedirect: {
            httpsRedirect: true,
            stripQuery: false,
        },
    });
    const _default = new gcp.compute.RegionTargetHttpProxy("default", {
        region: "us-central1",
        name: "test-https-redirect-proxy",
        urlMap: defaultRegionUrlMap.id,
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default_region_url_map = gcp.compute.RegionUrlMap("default",
        region="us-central1",
        name="url-map",
        default_url_redirect=gcp.compute.RegionUrlMapDefaultUrlRedirectArgs(
            https_redirect=True,
            strip_query=False,
        ))
    default = gcp.compute.RegionTargetHttpProxy("default",
        region="us-central1",
        name="test-https-redirect-proxy",
        url_map=default_region_url_map.id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/compute"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		defaultRegionUrlMap, err := compute.NewRegionUrlMap(ctx, "default", &compute.RegionUrlMapArgs{
    			Region: pulumi.String("us-central1"),
    			Name:   pulumi.String("url-map"),
    			DefaultUrlRedirect: &compute.RegionUrlMapDefaultUrlRedirectArgs{
    				HttpsRedirect: pulumi.Bool(true),
    				StripQuery:    pulumi.Bool(false),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = compute.NewRegionTargetHttpProxy(ctx, "default", &compute.RegionTargetHttpProxyArgs{
    			Region: pulumi.String("us-central1"),
    			Name:   pulumi.String("test-https-redirect-proxy"),
    			UrlMap: defaultRegionUrlMap.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var defaultRegionUrlMap = new Gcp.Compute.RegionUrlMap("default", new()
        {
            Region = "us-central1",
            Name = "url-map",
            DefaultUrlRedirect = new Gcp.Compute.Inputs.RegionUrlMapDefaultUrlRedirectArgs
            {
                HttpsRedirect = true,
                StripQuery = false,
            },
        });
    
        var @default = new Gcp.Compute.RegionTargetHttpProxy("default", new()
        {
            Region = "us-central1",
            Name = "test-https-redirect-proxy",
            UrlMap = defaultRegionUrlMap.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.compute.RegionUrlMap;
    import com.pulumi.gcp.compute.RegionUrlMapArgs;
    import com.pulumi.gcp.compute.inputs.RegionUrlMapDefaultUrlRedirectArgs;
    import com.pulumi.gcp.compute.RegionTargetHttpProxy;
    import com.pulumi.gcp.compute.RegionTargetHttpProxyArgs;
    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 defaultRegionUrlMap = new RegionUrlMap("defaultRegionUrlMap", RegionUrlMapArgs.builder()        
                .region("us-central1")
                .name("url-map")
                .defaultUrlRedirect(RegionUrlMapDefaultUrlRedirectArgs.builder()
                    .httpsRedirect(true)
                    .stripQuery(false)
                    .build())
                .build());
    
            var default_ = new RegionTargetHttpProxy("default", RegionTargetHttpProxyArgs.builder()        
                .region("us-central1")
                .name("test-https-redirect-proxy")
                .urlMap(defaultRegionUrlMap.id())
                .build());
    
        }
    }
    
    resources:
      default:
        type: gcp:compute:RegionTargetHttpProxy
        properties:
          region: us-central1
          name: test-https-redirect-proxy
          urlMap: ${defaultRegionUrlMap.id}
      defaultRegionUrlMap:
        type: gcp:compute:RegionUrlMap
        name: default
        properties:
          region: us-central1
          name: url-map
          defaultUrlRedirect:
            httpsRedirect: true
            stripQuery: false
    

    Create RegionTargetHttpProxy Resource

    new RegionTargetHttpProxy(name: string, args: RegionTargetHttpProxyArgs, opts?: CustomResourceOptions);
    @overload
    def RegionTargetHttpProxy(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              description: Optional[str] = None,
                              name: Optional[str] = None,
                              project: Optional[str] = None,
                              region: Optional[str] = None,
                              url_map: Optional[str] = None)
    @overload
    def RegionTargetHttpProxy(resource_name: str,
                              args: RegionTargetHttpProxyArgs,
                              opts: Optional[ResourceOptions] = None)
    func NewRegionTargetHttpProxy(ctx *Context, name string, args RegionTargetHttpProxyArgs, opts ...ResourceOption) (*RegionTargetHttpProxy, error)
    public RegionTargetHttpProxy(string name, RegionTargetHttpProxyArgs args, CustomResourceOptions? opts = null)
    public RegionTargetHttpProxy(String name, RegionTargetHttpProxyArgs args)
    public RegionTargetHttpProxy(String name, RegionTargetHttpProxyArgs args, CustomResourceOptions options)
    
    type: gcp:compute:RegionTargetHttpProxy
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args RegionTargetHttpProxyArgs
    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 RegionTargetHttpProxyArgs
    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 RegionTargetHttpProxyArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args RegionTargetHttpProxyArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args RegionTargetHttpProxyArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    UrlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    Description string
    An optional description of this resource.
    Name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    Region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    UrlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    Description string
    An optional description of this resource.
    Name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    Region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    urlMap String
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    description String
    An optional description of this resource.
    name String
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    region String
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    urlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    description string
    An optional description of this resource.
    name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    url_map str
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    description str
    An optional description of this resource.
    name str
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    region str
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    urlMap String
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    description String
    An optional description of this resource.
    name String
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    region String
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.

    Outputs

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

    CreationTimestamp string
    Creation timestamp in RFC3339 text format.
    Id string
    The provider-assigned unique ID for this managed resource.
    ProxyId int
    The unique identifier for the resource.
    SelfLink string
    The URI of the created resource.
    CreationTimestamp string
    Creation timestamp in RFC3339 text format.
    Id string
    The provider-assigned unique ID for this managed resource.
    ProxyId int
    The unique identifier for the resource.
    SelfLink string
    The URI of the created resource.
    creationTimestamp String
    Creation timestamp in RFC3339 text format.
    id String
    The provider-assigned unique ID for this managed resource.
    proxyId Integer
    The unique identifier for the resource.
    selfLink String
    The URI of the created resource.
    creationTimestamp string
    Creation timestamp in RFC3339 text format.
    id string
    The provider-assigned unique ID for this managed resource.
    proxyId number
    The unique identifier for the resource.
    selfLink string
    The URI of the created resource.
    creation_timestamp str
    Creation timestamp in RFC3339 text format.
    id str
    The provider-assigned unique ID for this managed resource.
    proxy_id int
    The unique identifier for the resource.
    self_link str
    The URI of the created resource.
    creationTimestamp String
    Creation timestamp in RFC3339 text format.
    id String
    The provider-assigned unique ID for this managed resource.
    proxyId Number
    The unique identifier for the resource.
    selfLink String
    The URI of the created resource.

    Look up Existing RegionTargetHttpProxy Resource

    Get an existing RegionTargetHttpProxy 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?: RegionTargetHttpProxyState, opts?: CustomResourceOptions): RegionTargetHttpProxy
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            creation_timestamp: Optional[str] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            project: Optional[str] = None,
            proxy_id: Optional[int] = None,
            region: Optional[str] = None,
            self_link: Optional[str] = None,
            url_map: Optional[str] = None) -> RegionTargetHttpProxy
    func GetRegionTargetHttpProxy(ctx *Context, name string, id IDInput, state *RegionTargetHttpProxyState, opts ...ResourceOption) (*RegionTargetHttpProxy, error)
    public static RegionTargetHttpProxy Get(string name, Input<string> id, RegionTargetHttpProxyState? state, CustomResourceOptions? opts = null)
    public static RegionTargetHttpProxy get(String name, Output<String> id, RegionTargetHttpProxyState 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:
    CreationTimestamp string
    Creation timestamp in RFC3339 text format.
    Description string
    An optional description of this resource.
    Name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    ProxyId int
    The unique identifier for the resource.
    Region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    SelfLink string
    The URI of the created resource.
    UrlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    CreationTimestamp string
    Creation timestamp in RFC3339 text format.
    Description string
    An optional description of this resource.
    Name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    ProxyId int
    The unique identifier for the resource.
    Region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    SelfLink string
    The URI of the created resource.
    UrlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    creationTimestamp String
    Creation timestamp in RFC3339 text format.
    description String
    An optional description of this resource.
    name String
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    proxyId Integer
    The unique identifier for the resource.
    region String
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    selfLink String
    The URI of the created resource.
    urlMap String
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    creationTimestamp string
    Creation timestamp in RFC3339 text format.
    description string
    An optional description of this resource.
    name string
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    proxyId number
    The unique identifier for the resource.
    region string
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    selfLink string
    The URI of the created resource.
    urlMap string
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    creation_timestamp str
    Creation timestamp in RFC3339 text format.
    description str
    An optional description of this resource.
    name str
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    proxy_id int
    The unique identifier for the resource.
    region str
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    self_link str
    The URI of the created resource.
    url_map str
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    creationTimestamp String
    Creation timestamp in RFC3339 text format.
    description String
    An optional description of this resource.
    name String
    Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    proxyId Number
    The unique identifier for the resource.
    region String
    The Region in which the created target https proxy should reside. If it is not provided, the provider region is used.
    selfLink String
    The URI of the created resource.
    urlMap String
    A reference to the RegionUrlMap resource that defines the mapping from URL to the BackendService.


    Import

    RegionTargetHttpProxy can be imported using any of these accepted formats:

    • projects/{{project}}/regions/{{region}}/targetHttpProxies/{{name}}

    • {{project}}/{{region}}/{{name}}

    • {{region}}/{{name}}

    • {{name}}

    When using the pulumi import command, RegionTargetHttpProxy can be imported using one of the formats above. For example:

    $ pulumi import gcp:compute/regionTargetHttpProxy:RegionTargetHttpProxy default projects/{{project}}/regions/{{region}}/targetHttpProxies/{{name}}
    
    $ pulumi import gcp:compute/regionTargetHttpProxy:RegionTargetHttpProxy default {{project}}/{{region}}/{{name}}
    
    $ pulumi import gcp:compute/regionTargetHttpProxy:RegionTargetHttpProxy default {{region}}/{{name}}
    
    $ pulumi import gcp:compute/regionTargetHttpProxy:RegionTargetHttpProxy default {{name}}
    

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Google Cloud Classic v7.16.0 published on Wednesday, Mar 27, 2024 by Pulumi