github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/datasync/locationFsxOntapFileSystem.go (about) 1 // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT. 2 // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! *** 3 4 package datasync 5 6 import ( 7 "context" 8 "reflect" 9 10 "errors" 11 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 12 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 13 ) 14 15 // Resource for managing an AWS DataSync Location FSx Ontap File System. 16 // 17 // ## Example Usage 18 // 19 // ## Import 20 // 21 // Using `pulumi import`, import `aws_datasync_location_fsx_ontap_file_system` using the `DataSync-ARN#FSx-ontap-svm-ARN`. For example: 22 // 23 // ```sh 24 // $ pulumi import aws:datasync/locationFsxOntapFileSystem:LocationFsxOntapFileSystem example arn:aws:datasync:us-west-2:123456789012:location/loc-12345678901234567#arn:aws:fsx:us-west-2:123456789012:storage-virtual-machine/svm-12345678abcdef123 25 // ``` 26 type LocationFsxOntapFileSystem struct { 27 pulumi.CustomResourceState 28 29 // ARN of the DataSync Location for the FSx Ontap File System. 30 Arn pulumi.StringOutput `pulumi:"arn"` 31 CreationTime pulumi.StringOutput `pulumi:"creationTime"` 32 // ARN of the FSx Ontap File System. 33 FsxFilesystemArn pulumi.StringOutput `pulumi:"fsxFilesystemArn"` 34 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 35 Protocol LocationFsxOntapFileSystemProtocolOutput `pulumi:"protocol"` 36 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 37 // * Network File System (NFS): TCP ports 111, 635, and 2049 38 // * Server Message Block (SMB): TCP port 445 39 SecurityGroupArns pulumi.StringArrayOutput `pulumi:"securityGroupArns"` 40 // The ARN of the SVM in your file system where you want to copy data to of from. 41 // 42 // The following arguments are optional: 43 StorageVirtualMachineArn pulumi.StringOutput `pulumi:"storageVirtualMachineArn"` 44 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 45 Subdirectory pulumi.StringOutput `pulumi:"subdirectory"` 46 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 47 Tags pulumi.StringMapOutput `pulumi:"tags"` 48 // Deprecated: Please use `tags` instead. 49 TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"` 50 // URI of the FSx ONTAP file system location 51 Uri pulumi.StringOutput `pulumi:"uri"` 52 } 53 54 // NewLocationFsxOntapFileSystem registers a new resource with the given unique name, arguments, and options. 55 func NewLocationFsxOntapFileSystem(ctx *pulumi.Context, 56 name string, args *LocationFsxOntapFileSystemArgs, opts ...pulumi.ResourceOption) (*LocationFsxOntapFileSystem, error) { 57 if args == nil { 58 return nil, errors.New("missing one or more required arguments") 59 } 60 61 if args.Protocol == nil { 62 return nil, errors.New("invalid value for required argument 'Protocol'") 63 } 64 if args.SecurityGroupArns == nil { 65 return nil, errors.New("invalid value for required argument 'SecurityGroupArns'") 66 } 67 if args.StorageVirtualMachineArn == nil { 68 return nil, errors.New("invalid value for required argument 'StorageVirtualMachineArn'") 69 } 70 opts = internal.PkgResourceDefaultOpts(opts) 71 var resource LocationFsxOntapFileSystem 72 err := ctx.RegisterResource("aws:datasync/locationFsxOntapFileSystem:LocationFsxOntapFileSystem", name, args, &resource, opts...) 73 if err != nil { 74 return nil, err 75 } 76 return &resource, nil 77 } 78 79 // GetLocationFsxOntapFileSystem gets an existing LocationFsxOntapFileSystem resource's state with the given name, ID, and optional 80 // state properties that are used to uniquely qualify the lookup (nil if not required). 81 func GetLocationFsxOntapFileSystem(ctx *pulumi.Context, 82 name string, id pulumi.IDInput, state *LocationFsxOntapFileSystemState, opts ...pulumi.ResourceOption) (*LocationFsxOntapFileSystem, error) { 83 var resource LocationFsxOntapFileSystem 84 err := ctx.ReadResource("aws:datasync/locationFsxOntapFileSystem:LocationFsxOntapFileSystem", name, id, state, &resource, opts...) 85 if err != nil { 86 return nil, err 87 } 88 return &resource, nil 89 } 90 91 // Input properties used for looking up and filtering LocationFsxOntapFileSystem resources. 92 type locationFsxOntapFileSystemState struct { 93 // ARN of the DataSync Location for the FSx Ontap File System. 94 Arn *string `pulumi:"arn"` 95 CreationTime *string `pulumi:"creationTime"` 96 // ARN of the FSx Ontap File System. 97 FsxFilesystemArn *string `pulumi:"fsxFilesystemArn"` 98 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 99 Protocol *LocationFsxOntapFileSystemProtocol `pulumi:"protocol"` 100 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 101 // * Network File System (NFS): TCP ports 111, 635, and 2049 102 // * Server Message Block (SMB): TCP port 445 103 SecurityGroupArns []string `pulumi:"securityGroupArns"` 104 // The ARN of the SVM in your file system where you want to copy data to of from. 105 // 106 // The following arguments are optional: 107 StorageVirtualMachineArn *string `pulumi:"storageVirtualMachineArn"` 108 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 109 Subdirectory *string `pulumi:"subdirectory"` 110 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 111 Tags map[string]string `pulumi:"tags"` 112 // Deprecated: Please use `tags` instead. 113 TagsAll map[string]string `pulumi:"tagsAll"` 114 // URI of the FSx ONTAP file system location 115 Uri *string `pulumi:"uri"` 116 } 117 118 type LocationFsxOntapFileSystemState struct { 119 // ARN of the DataSync Location for the FSx Ontap File System. 120 Arn pulumi.StringPtrInput 121 CreationTime pulumi.StringPtrInput 122 // ARN of the FSx Ontap File System. 123 FsxFilesystemArn pulumi.StringPtrInput 124 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 125 Protocol LocationFsxOntapFileSystemProtocolPtrInput 126 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 127 // * Network File System (NFS): TCP ports 111, 635, and 2049 128 // * Server Message Block (SMB): TCP port 445 129 SecurityGroupArns pulumi.StringArrayInput 130 // The ARN of the SVM in your file system where you want to copy data to of from. 131 // 132 // The following arguments are optional: 133 StorageVirtualMachineArn pulumi.StringPtrInput 134 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 135 Subdirectory pulumi.StringPtrInput 136 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 137 Tags pulumi.StringMapInput 138 // Deprecated: Please use `tags` instead. 139 TagsAll pulumi.StringMapInput 140 // URI of the FSx ONTAP file system location 141 Uri pulumi.StringPtrInput 142 } 143 144 func (LocationFsxOntapFileSystemState) ElementType() reflect.Type { 145 return reflect.TypeOf((*locationFsxOntapFileSystemState)(nil)).Elem() 146 } 147 148 type locationFsxOntapFileSystemArgs struct { 149 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 150 Protocol LocationFsxOntapFileSystemProtocol `pulumi:"protocol"` 151 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 152 // * Network File System (NFS): TCP ports 111, 635, and 2049 153 // * Server Message Block (SMB): TCP port 445 154 SecurityGroupArns []string `pulumi:"securityGroupArns"` 155 // The ARN of the SVM in your file system where you want to copy data to of from. 156 // 157 // The following arguments are optional: 158 StorageVirtualMachineArn string `pulumi:"storageVirtualMachineArn"` 159 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 160 Subdirectory *string `pulumi:"subdirectory"` 161 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 162 Tags map[string]string `pulumi:"tags"` 163 } 164 165 // The set of arguments for constructing a LocationFsxOntapFileSystem resource. 166 type LocationFsxOntapFileSystemArgs struct { 167 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 168 Protocol LocationFsxOntapFileSystemProtocolInput 169 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 170 // * Network File System (NFS): TCP ports 111, 635, and 2049 171 // * Server Message Block (SMB): TCP port 445 172 SecurityGroupArns pulumi.StringArrayInput 173 // The ARN of the SVM in your file system where you want to copy data to of from. 174 // 175 // The following arguments are optional: 176 StorageVirtualMachineArn pulumi.StringInput 177 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 178 Subdirectory pulumi.StringPtrInput 179 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 180 Tags pulumi.StringMapInput 181 } 182 183 func (LocationFsxOntapFileSystemArgs) ElementType() reflect.Type { 184 return reflect.TypeOf((*locationFsxOntapFileSystemArgs)(nil)).Elem() 185 } 186 187 type LocationFsxOntapFileSystemInput interface { 188 pulumi.Input 189 190 ToLocationFsxOntapFileSystemOutput() LocationFsxOntapFileSystemOutput 191 ToLocationFsxOntapFileSystemOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemOutput 192 } 193 194 func (*LocationFsxOntapFileSystem) ElementType() reflect.Type { 195 return reflect.TypeOf((**LocationFsxOntapFileSystem)(nil)).Elem() 196 } 197 198 func (i *LocationFsxOntapFileSystem) ToLocationFsxOntapFileSystemOutput() LocationFsxOntapFileSystemOutput { 199 return i.ToLocationFsxOntapFileSystemOutputWithContext(context.Background()) 200 } 201 202 func (i *LocationFsxOntapFileSystem) ToLocationFsxOntapFileSystemOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemOutput { 203 return pulumi.ToOutputWithContext(ctx, i).(LocationFsxOntapFileSystemOutput) 204 } 205 206 // LocationFsxOntapFileSystemArrayInput is an input type that accepts LocationFsxOntapFileSystemArray and LocationFsxOntapFileSystemArrayOutput values. 207 // You can construct a concrete instance of `LocationFsxOntapFileSystemArrayInput` via: 208 // 209 // LocationFsxOntapFileSystemArray{ LocationFsxOntapFileSystemArgs{...} } 210 type LocationFsxOntapFileSystemArrayInput interface { 211 pulumi.Input 212 213 ToLocationFsxOntapFileSystemArrayOutput() LocationFsxOntapFileSystemArrayOutput 214 ToLocationFsxOntapFileSystemArrayOutputWithContext(context.Context) LocationFsxOntapFileSystemArrayOutput 215 } 216 217 type LocationFsxOntapFileSystemArray []LocationFsxOntapFileSystemInput 218 219 func (LocationFsxOntapFileSystemArray) ElementType() reflect.Type { 220 return reflect.TypeOf((*[]*LocationFsxOntapFileSystem)(nil)).Elem() 221 } 222 223 func (i LocationFsxOntapFileSystemArray) ToLocationFsxOntapFileSystemArrayOutput() LocationFsxOntapFileSystemArrayOutput { 224 return i.ToLocationFsxOntapFileSystemArrayOutputWithContext(context.Background()) 225 } 226 227 func (i LocationFsxOntapFileSystemArray) ToLocationFsxOntapFileSystemArrayOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemArrayOutput { 228 return pulumi.ToOutputWithContext(ctx, i).(LocationFsxOntapFileSystemArrayOutput) 229 } 230 231 // LocationFsxOntapFileSystemMapInput is an input type that accepts LocationFsxOntapFileSystemMap and LocationFsxOntapFileSystemMapOutput values. 232 // You can construct a concrete instance of `LocationFsxOntapFileSystemMapInput` via: 233 // 234 // LocationFsxOntapFileSystemMap{ "key": LocationFsxOntapFileSystemArgs{...} } 235 type LocationFsxOntapFileSystemMapInput interface { 236 pulumi.Input 237 238 ToLocationFsxOntapFileSystemMapOutput() LocationFsxOntapFileSystemMapOutput 239 ToLocationFsxOntapFileSystemMapOutputWithContext(context.Context) LocationFsxOntapFileSystemMapOutput 240 } 241 242 type LocationFsxOntapFileSystemMap map[string]LocationFsxOntapFileSystemInput 243 244 func (LocationFsxOntapFileSystemMap) ElementType() reflect.Type { 245 return reflect.TypeOf((*map[string]*LocationFsxOntapFileSystem)(nil)).Elem() 246 } 247 248 func (i LocationFsxOntapFileSystemMap) ToLocationFsxOntapFileSystemMapOutput() LocationFsxOntapFileSystemMapOutput { 249 return i.ToLocationFsxOntapFileSystemMapOutputWithContext(context.Background()) 250 } 251 252 func (i LocationFsxOntapFileSystemMap) ToLocationFsxOntapFileSystemMapOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemMapOutput { 253 return pulumi.ToOutputWithContext(ctx, i).(LocationFsxOntapFileSystemMapOutput) 254 } 255 256 type LocationFsxOntapFileSystemOutput struct{ *pulumi.OutputState } 257 258 func (LocationFsxOntapFileSystemOutput) ElementType() reflect.Type { 259 return reflect.TypeOf((**LocationFsxOntapFileSystem)(nil)).Elem() 260 } 261 262 func (o LocationFsxOntapFileSystemOutput) ToLocationFsxOntapFileSystemOutput() LocationFsxOntapFileSystemOutput { 263 return o 264 } 265 266 func (o LocationFsxOntapFileSystemOutput) ToLocationFsxOntapFileSystemOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemOutput { 267 return o 268 } 269 270 // ARN of the DataSync Location for the FSx Ontap File System. 271 func (o LocationFsxOntapFileSystemOutput) Arn() pulumi.StringOutput { 272 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput) 273 } 274 275 func (o LocationFsxOntapFileSystemOutput) CreationTime() pulumi.StringOutput { 276 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.CreationTime }).(pulumi.StringOutput) 277 } 278 279 // ARN of the FSx Ontap File System. 280 func (o LocationFsxOntapFileSystemOutput) FsxFilesystemArn() pulumi.StringOutput { 281 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.FsxFilesystemArn }).(pulumi.StringOutput) 282 } 283 284 // The data transfer protocol that DataSync uses to access your Amazon FSx file system. See Protocol below. 285 func (o LocationFsxOntapFileSystemOutput) Protocol() LocationFsxOntapFileSystemProtocolOutput { 286 return o.ApplyT(func(v *LocationFsxOntapFileSystem) LocationFsxOntapFileSystemProtocolOutput { return v.Protocol }).(LocationFsxOntapFileSystemProtocolOutput) 287 } 288 289 // The security groups that provide access to your file system's preferred subnet. The security groups must allow outbbound traffic on the following ports (depending on the protocol you use): 290 // * Network File System (NFS): TCP ports 111, 635, and 2049 291 // * Server Message Block (SMB): TCP port 445 292 func (o LocationFsxOntapFileSystemOutput) SecurityGroupArns() pulumi.StringArrayOutput { 293 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringArrayOutput { return v.SecurityGroupArns }).(pulumi.StringArrayOutput) 294 } 295 296 // The ARN of the SVM in your file system where you want to copy data to of from. 297 // 298 // The following arguments are optional: 299 func (o LocationFsxOntapFileSystemOutput) StorageVirtualMachineArn() pulumi.StringOutput { 300 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.StorageVirtualMachineArn }).(pulumi.StringOutput) 301 } 302 303 // Path to the file share in the SVM where you'll copy your data. You can specify a junction path (also known as a mount point), qtree path (for NFS file shares), or share name (for SMB file shares) (e.g. `/vol1`, `/vol1/tree1`, `share1`). 304 func (o LocationFsxOntapFileSystemOutput) Subdirectory() pulumi.StringOutput { 305 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.Subdirectory }).(pulumi.StringOutput) 306 } 307 308 // Key-value pairs of resource tags to assign to the DataSync Location. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. 309 func (o LocationFsxOntapFileSystemOutput) Tags() pulumi.StringMapOutput { 310 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput) 311 } 312 313 // Deprecated: Please use `tags` instead. 314 func (o LocationFsxOntapFileSystemOutput) TagsAll() pulumi.StringMapOutput { 315 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput) 316 } 317 318 // URI of the FSx ONTAP file system location 319 func (o LocationFsxOntapFileSystemOutput) Uri() pulumi.StringOutput { 320 return o.ApplyT(func(v *LocationFsxOntapFileSystem) pulumi.StringOutput { return v.Uri }).(pulumi.StringOutput) 321 } 322 323 type LocationFsxOntapFileSystemArrayOutput struct{ *pulumi.OutputState } 324 325 func (LocationFsxOntapFileSystemArrayOutput) ElementType() reflect.Type { 326 return reflect.TypeOf((*[]*LocationFsxOntapFileSystem)(nil)).Elem() 327 } 328 329 func (o LocationFsxOntapFileSystemArrayOutput) ToLocationFsxOntapFileSystemArrayOutput() LocationFsxOntapFileSystemArrayOutput { 330 return o 331 } 332 333 func (o LocationFsxOntapFileSystemArrayOutput) ToLocationFsxOntapFileSystemArrayOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemArrayOutput { 334 return o 335 } 336 337 func (o LocationFsxOntapFileSystemArrayOutput) Index(i pulumi.IntInput) LocationFsxOntapFileSystemOutput { 338 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *LocationFsxOntapFileSystem { 339 return vs[0].([]*LocationFsxOntapFileSystem)[vs[1].(int)] 340 }).(LocationFsxOntapFileSystemOutput) 341 } 342 343 type LocationFsxOntapFileSystemMapOutput struct{ *pulumi.OutputState } 344 345 func (LocationFsxOntapFileSystemMapOutput) ElementType() reflect.Type { 346 return reflect.TypeOf((*map[string]*LocationFsxOntapFileSystem)(nil)).Elem() 347 } 348 349 func (o LocationFsxOntapFileSystemMapOutput) ToLocationFsxOntapFileSystemMapOutput() LocationFsxOntapFileSystemMapOutput { 350 return o 351 } 352 353 func (o LocationFsxOntapFileSystemMapOutput) ToLocationFsxOntapFileSystemMapOutputWithContext(ctx context.Context) LocationFsxOntapFileSystemMapOutput { 354 return o 355 } 356 357 func (o LocationFsxOntapFileSystemMapOutput) MapIndex(k pulumi.StringInput) LocationFsxOntapFileSystemOutput { 358 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *LocationFsxOntapFileSystem { 359 return vs[0].(map[string]*LocationFsxOntapFileSystem)[vs[1].(string)] 360 }).(LocationFsxOntapFileSystemOutput) 361 } 362 363 func init() { 364 pulumi.RegisterInputType(reflect.TypeOf((*LocationFsxOntapFileSystemInput)(nil)).Elem(), &LocationFsxOntapFileSystem{}) 365 pulumi.RegisterInputType(reflect.TypeOf((*LocationFsxOntapFileSystemArrayInput)(nil)).Elem(), LocationFsxOntapFileSystemArray{}) 366 pulumi.RegisterInputType(reflect.TypeOf((*LocationFsxOntapFileSystemMapInput)(nil)).Elem(), LocationFsxOntapFileSystemMap{}) 367 pulumi.RegisterOutputType(LocationFsxOntapFileSystemOutput{}) 368 pulumi.RegisterOutputType(LocationFsxOntapFileSystemArrayOutput{}) 369 pulumi.RegisterOutputType(LocationFsxOntapFileSystemMapOutput{}) 370 }