/
getTargetHttpProxy.go
155 lines (129 loc) · 11.2 KB
/
getTargetHttpProxy.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
// Code generated by the Pulumi SDK Generator DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package alpha
import (
"context"
"reflect"
"github.com/pulumi/pulumi-google-native/sdk/go/google/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Returns the specified TargetHttpProxy resource.
func LookupTargetHttpProxy(ctx *pulumi.Context, args *LookupTargetHttpProxyArgs, opts ...pulumi.InvokeOption) (*LookupTargetHttpProxyResult, error) {
opts = internal.PkgInvokeDefaultOpts(opts)
var rv LookupTargetHttpProxyResult
err := ctx.Invoke("google-native:compute/alpha:getTargetHttpProxy", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
type LookupTargetHttpProxyArgs struct {
Project *string `pulumi:"project"`
TargetHttpProxy string `pulumi:"targetHttpProxy"`
}
type LookupTargetHttpProxyResult struct {
// Creation timestamp in RFC3339 text format.
CreationTimestamp string `pulumi:"creationTimestamp"`
// An optional description of this resource. Provide this property when you create the resource.
Description string `pulumi:"description"`
// Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a TargetHttpProxy. An up-to-date fingerprint must be provided in order to patch/update the TargetHttpProxy; otherwise, the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the TargetHttpProxy.
Fingerprint string `pulumi:"fingerprint"`
// URLs to networkservices.HttpFilter resources enabled for xDS clients using this configuration. For example, https://networkservices.googleapis.com/v1alpha1/projects/project/locations/ locationhttpFilters/httpFilter Only filters that handle outbound connection and stream events may be specified. These filters work in conjunction with a default set of HTTP filters that may already be configured by Traffic Director. Traffic Director will determine the final location of these filters within xDS configuration based on the name of the HTTP filter. If Traffic Director positions multiple filters at the same location, those filters will be in the same order as specified in this list. httpFilters only applies for loadbalancers with loadBalancingScheme set to INTERNAL_SELF_MANAGED. See ForwardingRule for more details.
HttpFilters []string `pulumi:"httpFilters"`
// Specifies how long to keep a connection open, after completing a response, while there is no matching traffic (in seconds). If an HTTP keep-alive is not specified, a default value (610 seconds) will be used. For global external Application Load Balancers, the minimum allowed value is 5 seconds and the maximum allowed value is 1200 seconds. For classic Application Load Balancers, this option is not supported.
HttpKeepAliveTimeoutSec int `pulumi:"httpKeepAliveTimeoutSec"`
// Type of resource. Always compute#targetHttpProxy for target HTTP proxies.
Kind string `pulumi:"kind"`
// 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]([-a-z0-9]*[a-z0-9])?` 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.
Name string `pulumi:"name"`
// This field only applies when the forwarding rule that references this target proxy has a loadBalancingScheme set to INTERNAL_SELF_MANAGED. When this field is set to true, Envoy proxies set up inbound traffic interception and bind to the IP address and port specified in the forwarding rule. This is generally useful when using Traffic Director to configure Envoy as a gateway or middle proxy (in other words, not a sidecar proxy). The Envoy proxy listens for inbound requests and handles requests when it receives them. The default is false.
ProxyBind bool `pulumi:"proxyBind"`
// URL of the region where the regional Target HTTP Proxy resides. This field is not applicable to global Target HTTP Proxies.
Region string `pulumi:"region"`
// Server-defined URL for the resource.
SelfLink string `pulumi:"selfLink"`
// Server-defined URL for this resource with the resource id.
SelfLinkWithId string `pulumi:"selfLinkWithId"`
// URL to the UrlMap resource that defines the mapping from URL to the BackendService.
UrlMap string `pulumi:"urlMap"`
}
func LookupTargetHttpProxyOutput(ctx *pulumi.Context, args LookupTargetHttpProxyOutputArgs, opts ...pulumi.InvokeOption) LookupTargetHttpProxyResultOutput {
return pulumi.ToOutputWithContext(context.Background(), args).
ApplyT(func(v interface{}) (LookupTargetHttpProxyResult, error) {
args := v.(LookupTargetHttpProxyArgs)
r, err := LookupTargetHttpProxy(ctx, &args, opts...)
var s LookupTargetHttpProxyResult
if r != nil {
s = *r
}
return s, err
}).(LookupTargetHttpProxyResultOutput)
}
type LookupTargetHttpProxyOutputArgs struct {
Project pulumi.StringPtrInput `pulumi:"project"`
TargetHttpProxy pulumi.StringInput `pulumi:"targetHttpProxy"`
}
func (LookupTargetHttpProxyOutputArgs) ElementType() reflect.Type {
return reflect.TypeOf((*LookupTargetHttpProxyArgs)(nil)).Elem()
}
type LookupTargetHttpProxyResultOutput struct{ *pulumi.OutputState }
func (LookupTargetHttpProxyResultOutput) ElementType() reflect.Type {
return reflect.TypeOf((*LookupTargetHttpProxyResult)(nil)).Elem()
}
func (o LookupTargetHttpProxyResultOutput) ToLookupTargetHttpProxyResultOutput() LookupTargetHttpProxyResultOutput {
return o
}
func (o LookupTargetHttpProxyResultOutput) ToLookupTargetHttpProxyResultOutputWithContext(ctx context.Context) LookupTargetHttpProxyResultOutput {
return o
}
// Creation timestamp in RFC3339 text format.
func (o LookupTargetHttpProxyResultOutput) CreationTimestamp() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.CreationTimestamp }).(pulumi.StringOutput)
}
// An optional description of this resource. Provide this property when you create the resource.
func (o LookupTargetHttpProxyResultOutput) Description() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.Description }).(pulumi.StringOutput)
}
// Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a TargetHttpProxy. An up-to-date fingerprint must be provided in order to patch/update the TargetHttpProxy; otherwise, the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the TargetHttpProxy.
func (o LookupTargetHttpProxyResultOutput) Fingerprint() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.Fingerprint }).(pulumi.StringOutput)
}
// URLs to networkservices.HttpFilter resources enabled for xDS clients using this configuration. For example, https://networkservices.googleapis.com/v1alpha1/projects/project/locations/ locationhttpFilters/httpFilter Only filters that handle outbound connection and stream events may be specified. These filters work in conjunction with a default set of HTTP filters that may already be configured by Traffic Director. Traffic Director will determine the final location of these filters within xDS configuration based on the name of the HTTP filter. If Traffic Director positions multiple filters at the same location, those filters will be in the same order as specified in this list. httpFilters only applies for loadbalancers with loadBalancingScheme set to INTERNAL_SELF_MANAGED. See ForwardingRule for more details.
func (o LookupTargetHttpProxyResultOutput) HttpFilters() pulumi.StringArrayOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) []string { return v.HttpFilters }).(pulumi.StringArrayOutput)
}
// Specifies how long to keep a connection open, after completing a response, while there is no matching traffic (in seconds). If an HTTP keep-alive is not specified, a default value (610 seconds) will be used. For global external Application Load Balancers, the minimum allowed value is 5 seconds and the maximum allowed value is 1200 seconds. For classic Application Load Balancers, this option is not supported.
func (o LookupTargetHttpProxyResultOutput) HttpKeepAliveTimeoutSec() pulumi.IntOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) int { return v.HttpKeepAliveTimeoutSec }).(pulumi.IntOutput)
}
// Type of resource. Always compute#targetHttpProxy for target HTTP proxies.
func (o LookupTargetHttpProxyResultOutput) Kind() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.Kind }).(pulumi.StringOutput)
}
// 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]([-a-z0-9]*[a-z0-9])?` 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.
func (o LookupTargetHttpProxyResultOutput) Name() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.Name }).(pulumi.StringOutput)
}
// This field only applies when the forwarding rule that references this target proxy has a loadBalancingScheme set to INTERNAL_SELF_MANAGED. When this field is set to true, Envoy proxies set up inbound traffic interception and bind to the IP address and port specified in the forwarding rule. This is generally useful when using Traffic Director to configure Envoy as a gateway or middle proxy (in other words, not a sidecar proxy). The Envoy proxy listens for inbound requests and handles requests when it receives them. The default is false.
func (o LookupTargetHttpProxyResultOutput) ProxyBind() pulumi.BoolOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) bool { return v.ProxyBind }).(pulumi.BoolOutput)
}
// URL of the region where the regional Target HTTP Proxy resides. This field is not applicable to global Target HTTP Proxies.
func (o LookupTargetHttpProxyResultOutput) Region() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.Region }).(pulumi.StringOutput)
}
// Server-defined URL for the resource.
func (o LookupTargetHttpProxyResultOutput) SelfLink() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.SelfLink }).(pulumi.StringOutput)
}
// Server-defined URL for this resource with the resource id.
func (o LookupTargetHttpProxyResultOutput) SelfLinkWithId() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.SelfLinkWithId }).(pulumi.StringOutput)
}
// URL to the UrlMap resource that defines the mapping from URL to the BackendService.
func (o LookupTargetHttpProxyResultOutput) UrlMap() pulumi.StringOutput {
return o.ApplyT(func(v LookupTargetHttpProxyResult) string { return v.UrlMap }).(pulumi.StringOutput)
}
func init() {
pulumi.RegisterOutputType(LookupTargetHttpProxyResultOutput{})
}