generated from pulumi/pulumi-tf-provider-boilerplate
/
userPublicKeys.go
227 lines (181 loc) · 8.89 KB
/
userPublicKeys.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
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package snowflake
import (
"context"
"reflect"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
type UserPublicKeys struct {
pulumi.CustomResourceState
// Name of the user.
Name pulumi.StringOutput `pulumi:"name"`
// Specifies the user’s RSA public key; used for key-pair authentication. Must be on 1 line without header and trailer.
RsaPublicKey pulumi.StringPtrOutput `pulumi:"rsaPublicKey"`
// Specifies the user’s second RSA public key; used to rotate the public and Public keys for key-pair authentication based on an expiration schedule set by your organization. Must be on 1 line without header and trailer.
RsaPublicKey2 pulumi.StringPtrOutput `pulumi:"rsaPublicKey2"`
}
// NewUserPublicKeys registers a new resource with the given unique name, arguments, and options.
func NewUserPublicKeys(ctx *pulumi.Context,
name string, args *UserPublicKeysArgs, opts ...pulumi.ResourceOption) (*UserPublicKeys, error) {
if args == nil {
args = &UserPublicKeysArgs{}
}
var resource UserPublicKeys
err := ctx.RegisterResource("snowflake:index/userPublicKeys:UserPublicKeys", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetUserPublicKeys gets an existing UserPublicKeys resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetUserPublicKeys(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *UserPublicKeysState, opts ...pulumi.ResourceOption) (*UserPublicKeys, error) {
var resource UserPublicKeys
err := ctx.ReadResource("snowflake:index/userPublicKeys:UserPublicKeys", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering UserPublicKeys resources.
type userPublicKeysState struct {
// Name of the user.
Name *string `pulumi:"name"`
// Specifies the user’s RSA public key; used for key-pair authentication. Must be on 1 line without header and trailer.
RsaPublicKey *string `pulumi:"rsaPublicKey"`
// Specifies the user’s second RSA public key; used to rotate the public and Public keys for key-pair authentication based on an expiration schedule set by your organization. Must be on 1 line without header and trailer.
RsaPublicKey2 *string `pulumi:"rsaPublicKey2"`
}
type UserPublicKeysState struct {
// Name of the user.
Name pulumi.StringPtrInput
// Specifies the user’s RSA public key; used for key-pair authentication. Must be on 1 line without header and trailer.
RsaPublicKey pulumi.StringPtrInput
// Specifies the user’s second RSA public key; used to rotate the public and Public keys for key-pair authentication based on an expiration schedule set by your organization. Must be on 1 line without header and trailer.
RsaPublicKey2 pulumi.StringPtrInput
}
func (UserPublicKeysState) ElementType() reflect.Type {
return reflect.TypeOf((*userPublicKeysState)(nil)).Elem()
}
type userPublicKeysArgs struct {
// Name of the user.
Name *string `pulumi:"name"`
// Specifies the user’s RSA public key; used for key-pair authentication. Must be on 1 line without header and trailer.
RsaPublicKey *string `pulumi:"rsaPublicKey"`
// Specifies the user’s second RSA public key; used to rotate the public and Public keys for key-pair authentication based on an expiration schedule set by your organization. Must be on 1 line without header and trailer.
RsaPublicKey2 *string `pulumi:"rsaPublicKey2"`
}
// The set of arguments for constructing a UserPublicKeys resource.
type UserPublicKeysArgs struct {
// Name of the user.
Name pulumi.StringPtrInput
// Specifies the user’s RSA public key; used for key-pair authentication. Must be on 1 line without header and trailer.
RsaPublicKey pulumi.StringPtrInput
// Specifies the user’s second RSA public key; used to rotate the public and Public keys for key-pair authentication based on an expiration schedule set by your organization. Must be on 1 line without header and trailer.
RsaPublicKey2 pulumi.StringPtrInput
}
func (UserPublicKeysArgs) ElementType() reflect.Type {
return reflect.TypeOf((*userPublicKeysArgs)(nil)).Elem()
}
type UserPublicKeysInput interface {
pulumi.Input
ToUserPublicKeysOutput() UserPublicKeysOutput
ToUserPublicKeysOutputWithContext(ctx context.Context) UserPublicKeysOutput
}
func (*UserPublicKeys) ElementType() reflect.Type {
return reflect.TypeOf((**UserPublicKeys)(nil)).Elem()
}
func (i *UserPublicKeys) ToUserPublicKeysOutput() UserPublicKeysOutput {
return i.ToUserPublicKeysOutputWithContext(context.Background())
}
func (i *UserPublicKeys) ToUserPublicKeysOutputWithContext(ctx context.Context) UserPublicKeysOutput {
return pulumi.ToOutputWithContext(ctx, i).(UserPublicKeysOutput)
}
// UserPublicKeysArrayInput is an input type that accepts UserPublicKeysArray and UserPublicKeysArrayOutput values.
// You can construct a concrete instance of `UserPublicKeysArrayInput` via:
//
// UserPublicKeysArray{ UserPublicKeysArgs{...} }
type UserPublicKeysArrayInput interface {
pulumi.Input
ToUserPublicKeysArrayOutput() UserPublicKeysArrayOutput
ToUserPublicKeysArrayOutputWithContext(context.Context) UserPublicKeysArrayOutput
}
type UserPublicKeysArray []UserPublicKeysInput
func (UserPublicKeysArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*UserPublicKeys)(nil)).Elem()
}
func (i UserPublicKeysArray) ToUserPublicKeysArrayOutput() UserPublicKeysArrayOutput {
return i.ToUserPublicKeysArrayOutputWithContext(context.Background())
}
func (i UserPublicKeysArray) ToUserPublicKeysArrayOutputWithContext(ctx context.Context) UserPublicKeysArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(UserPublicKeysArrayOutput)
}
// UserPublicKeysMapInput is an input type that accepts UserPublicKeysMap and UserPublicKeysMapOutput values.
// You can construct a concrete instance of `UserPublicKeysMapInput` via:
//
// UserPublicKeysMap{ "key": UserPublicKeysArgs{...} }
type UserPublicKeysMapInput interface {
pulumi.Input
ToUserPublicKeysMapOutput() UserPublicKeysMapOutput
ToUserPublicKeysMapOutputWithContext(context.Context) UserPublicKeysMapOutput
}
type UserPublicKeysMap map[string]UserPublicKeysInput
func (UserPublicKeysMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*UserPublicKeys)(nil)).Elem()
}
func (i UserPublicKeysMap) ToUserPublicKeysMapOutput() UserPublicKeysMapOutput {
return i.ToUserPublicKeysMapOutputWithContext(context.Background())
}
func (i UserPublicKeysMap) ToUserPublicKeysMapOutputWithContext(ctx context.Context) UserPublicKeysMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(UserPublicKeysMapOutput)
}
type UserPublicKeysOutput struct{ *pulumi.OutputState }
func (UserPublicKeysOutput) ElementType() reflect.Type {
return reflect.TypeOf((**UserPublicKeys)(nil)).Elem()
}
func (o UserPublicKeysOutput) ToUserPublicKeysOutput() UserPublicKeysOutput {
return o
}
func (o UserPublicKeysOutput) ToUserPublicKeysOutputWithContext(ctx context.Context) UserPublicKeysOutput {
return o
}
type UserPublicKeysArrayOutput struct{ *pulumi.OutputState }
func (UserPublicKeysArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*UserPublicKeys)(nil)).Elem()
}
func (o UserPublicKeysArrayOutput) ToUserPublicKeysArrayOutput() UserPublicKeysArrayOutput {
return o
}
func (o UserPublicKeysArrayOutput) ToUserPublicKeysArrayOutputWithContext(ctx context.Context) UserPublicKeysArrayOutput {
return o
}
func (o UserPublicKeysArrayOutput) Index(i pulumi.IntInput) UserPublicKeysOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *UserPublicKeys {
return vs[0].([]*UserPublicKeys)[vs[1].(int)]
}).(UserPublicKeysOutput)
}
type UserPublicKeysMapOutput struct{ *pulumi.OutputState }
func (UserPublicKeysMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*UserPublicKeys)(nil)).Elem()
}
func (o UserPublicKeysMapOutput) ToUserPublicKeysMapOutput() UserPublicKeysMapOutput {
return o
}
func (o UserPublicKeysMapOutput) ToUserPublicKeysMapOutputWithContext(ctx context.Context) UserPublicKeysMapOutput {
return o
}
func (o UserPublicKeysMapOutput) MapIndex(k pulumi.StringInput) UserPublicKeysOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *UserPublicKeys {
return vs[0].(map[string]*UserPublicKeys)[vs[1].(string)]
}).(UserPublicKeysOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*UserPublicKeysInput)(nil)).Elem(), &UserPublicKeys{})
pulumi.RegisterInputType(reflect.TypeOf((*UserPublicKeysArrayInput)(nil)).Elem(), UserPublicKeysArray{})
pulumi.RegisterInputType(reflect.TypeOf((*UserPublicKeysMapInput)(nil)).Elem(), UserPublicKeysMap{})
pulumi.RegisterOutputType(UserPublicKeysOutput{})
pulumi.RegisterOutputType(UserPublicKeysArrayOutput{})
pulumi.RegisterOutputType(UserPublicKeysMapOutput{})
}