github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/rds/exportTask.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 rds 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 RDS (Relational Database) Export Task. 16 // 17 // ## Example Usage 18 // 19 // ### Basic Usage 20 // 21 // <!--Start PulumiCodeChooser --> 22 // ```go 23 // package main 24 // 25 // import ( 26 // 27 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/rds" 28 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 29 // 30 // ) 31 // 32 // func main() { 33 // pulumi.Run(func(ctx *pulumi.Context) error { 34 // _, err := rds.NewExportTask(ctx, "example", &rds.ExportTaskArgs{ 35 // ExportTaskIdentifier: pulumi.String("example"), 36 // SourceArn: pulumi.Any(exampleAwsDbSnapshot.DbSnapshotArn), 37 // S3BucketName: pulumi.Any(exampleAwsS3Bucket.Id), 38 // IamRoleArn: pulumi.Any(exampleAwsIamRole.Arn), 39 // KmsKeyId: pulumi.Any(exampleAwsKmsKey.Arn), 40 // }) 41 // if err != nil { 42 // return err 43 // } 44 // return nil 45 // }) 46 // } 47 // 48 // ``` 49 // <!--End PulumiCodeChooser --> 50 // 51 // ### Complete Usage 52 // 53 // <!--Start PulumiCodeChooser --> 54 // ```go 55 // package main 56 // 57 // import ( 58 // 59 // "encoding/json" 60 // "fmt" 61 // 62 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/iam" 63 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/kms" 64 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/rds" 65 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/s3" 66 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 67 // 68 // ) 69 // 70 // func main() { 71 // pulumi.Run(func(ctx *pulumi.Context) error { 72 // exampleBucketV2, err := s3.NewBucketV2(ctx, "example", &s3.BucketV2Args{ 73 // Bucket: pulumi.String("example"), 74 // ForceDestroy: pulumi.Bool(true), 75 // }) 76 // if err != nil { 77 // return err 78 // } 79 // _, err = s3.NewBucketAclV2(ctx, "example", &s3.BucketAclV2Args{ 80 // Bucket: exampleBucketV2.ID(), 81 // Acl: pulumi.String("private"), 82 // }) 83 // if err != nil { 84 // return err 85 // } 86 // tmpJSON0, err := json.Marshal(map[string]interface{}{ 87 // "Version": "2012-10-17", 88 // "Statement": []map[string]interface{}{ 89 // map[string]interface{}{ 90 // "Action": "sts:AssumeRole", 91 // "Effect": "Allow", 92 // "Sid": "", 93 // "Principal": map[string]interface{}{ 94 // "Service": "export.rds.amazonaws.com", 95 // }, 96 // }, 97 // }, 98 // }) 99 // if err != nil { 100 // return err 101 // } 102 // json0 := string(tmpJSON0) 103 // exampleRole, err := iam.NewRole(ctx, "example", &iam.RoleArgs{ 104 // Name: pulumi.String("example"), 105 // AssumeRolePolicy: pulumi.String(json0), 106 // }) 107 // if err != nil { 108 // return err 109 // } 110 // example := iam.GetPolicyDocumentOutput(ctx, iam.GetPolicyDocumentOutputArgs{ 111 // Statements: iam.GetPolicyDocumentStatementArray{ 112 // &iam.GetPolicyDocumentStatementArgs{ 113 // Actions: pulumi.StringArray{ 114 // pulumi.String("s3:ListAllMyBuckets"), 115 // }, 116 // Resources: pulumi.StringArray{ 117 // pulumi.String("*"), 118 // }, 119 // }, 120 // &iam.GetPolicyDocumentStatementArgs{ 121 // Actions: pulumi.StringArray{ 122 // pulumi.String("s3:GetBucketLocation"), 123 // pulumi.String("s3:ListBucket"), 124 // }, 125 // Resources: pulumi.StringArray{ 126 // exampleBucketV2.Arn, 127 // }, 128 // }, 129 // &iam.GetPolicyDocumentStatementArgs{ 130 // Actions: pulumi.StringArray{ 131 // pulumi.String("s3:GetObject"), 132 // pulumi.String("s3:PutObject"), 133 // pulumi.String("s3:DeleteObject"), 134 // }, 135 // Resources: pulumi.StringArray{ 136 // exampleBucketV2.Arn.ApplyT(func(arn string) (string, error) { 137 // return fmt.Sprintf("%v/*", arn), nil 138 // }).(pulumi.StringOutput), 139 // }, 140 // }, 141 // }, 142 // }, nil) 143 // examplePolicy, err := iam.NewPolicy(ctx, "example", &iam.PolicyArgs{ 144 // Name: pulumi.String("example"), 145 // Policy: example.ApplyT(func(example iam.GetPolicyDocumentResult) (*string, error) { 146 // return &example.Json, nil 147 // }).(pulumi.StringPtrOutput), 148 // }) 149 // if err != nil { 150 // return err 151 // } 152 // _, err = iam.NewRolePolicyAttachment(ctx, "example", &iam.RolePolicyAttachmentArgs{ 153 // Role: exampleRole.Name, 154 // PolicyArn: examplePolicy.Arn, 155 // }) 156 // if err != nil { 157 // return err 158 // } 159 // exampleKey, err := kms.NewKey(ctx, "example", &kms.KeyArgs{ 160 // DeletionWindowInDays: pulumi.Int(10), 161 // }) 162 // if err != nil { 163 // return err 164 // } 165 // exampleInstance, err := rds.NewInstance(ctx, "example", &rds.InstanceArgs{ 166 // Identifier: pulumi.String("example"), 167 // AllocatedStorage: pulumi.Int(10), 168 // DbName: pulumi.String("test"), 169 // Engine: pulumi.String("mysql"), 170 // EngineVersion: pulumi.String("5.7"), 171 // InstanceClass: pulumi.String(rds.InstanceType_T3_Micro), 172 // Username: pulumi.String("foo"), 173 // Password: pulumi.String("foobarbaz"), 174 // ParameterGroupName: pulumi.String("default.mysql5.7"), 175 // SkipFinalSnapshot: pulumi.Bool(true), 176 // }) 177 // if err != nil { 178 // return err 179 // } 180 // exampleSnapshot, err := rds.NewSnapshot(ctx, "example", &rds.SnapshotArgs{ 181 // DbInstanceIdentifier: exampleInstance.Identifier, 182 // DbSnapshotIdentifier: pulumi.String("example"), 183 // }) 184 // if err != nil { 185 // return err 186 // } 187 // _, err = rds.NewExportTask(ctx, "example", &rds.ExportTaskArgs{ 188 // ExportTaskIdentifier: pulumi.String("example"), 189 // SourceArn: exampleSnapshot.DbSnapshotArn, 190 // S3BucketName: exampleBucketV2.ID(), 191 // IamRoleArn: exampleRole.Arn, 192 // KmsKeyId: exampleKey.Arn, 193 // ExportOnlies: pulumi.StringArray{ 194 // pulumi.String("database"), 195 // }, 196 // S3Prefix: pulumi.String("my_prefix/example"), 197 // }) 198 // if err != nil { 199 // return err 200 // } 201 // return nil 202 // }) 203 // } 204 // 205 // ``` 206 // <!--End PulumiCodeChooser --> 207 // 208 // ## Import 209 // 210 // Using `pulumi import`, import a RDS (Relational Database) Export Task using the `export_task_identifier`. For example: 211 // 212 // ```sh 213 // $ pulumi import aws:rds/exportTask:ExportTask example example 214 // ``` 215 type ExportTask struct { 216 pulumi.CustomResourceState 217 218 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 219 ExportOnlies pulumi.StringArrayOutput `pulumi:"exportOnlies"` 220 // Unique identifier for the snapshot export task. 221 ExportTaskIdentifier pulumi.StringOutput `pulumi:"exportTaskIdentifier"` 222 // Reason the export failed, if it failed. 223 FailureCause pulumi.StringOutput `pulumi:"failureCause"` 224 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 225 IamRoleArn pulumi.StringOutput `pulumi:"iamRoleArn"` 226 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 227 KmsKeyId pulumi.StringOutput `pulumi:"kmsKeyId"` 228 // Progress of the snapshot export task as a percentage. 229 PercentProgress pulumi.IntOutput `pulumi:"percentProgress"` 230 // Name of the Amazon S3 bucket to export the snapshot to. 231 S3BucketName pulumi.StringOutput `pulumi:"s3BucketName"` 232 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 233 S3Prefix pulumi.StringOutput `pulumi:"s3Prefix"` 234 // Time that the snapshot was created. 235 SnapshotTime pulumi.StringOutput `pulumi:"snapshotTime"` 236 // Amazon Resource Name (ARN) of the snapshot to export. 237 // 238 // The following arguments are optional: 239 SourceArn pulumi.StringOutput `pulumi:"sourceArn"` 240 // Type of source for the export. 241 SourceType pulumi.StringOutput `pulumi:"sourceType"` 242 // Status of the export task. 243 Status pulumi.StringOutput `pulumi:"status"` 244 // Time that the snapshot export task completed. 245 TaskEndTime pulumi.StringOutput `pulumi:"taskEndTime"` 246 // Time that the snapshot export task started. 247 TaskStartTime pulumi.StringOutput `pulumi:"taskStartTime"` 248 Timeouts ExportTaskTimeoutsPtrOutput `pulumi:"timeouts"` 249 // Warning about the snapshot export task, if any. 250 WarningMessage pulumi.StringOutput `pulumi:"warningMessage"` 251 } 252 253 // NewExportTask registers a new resource with the given unique name, arguments, and options. 254 func NewExportTask(ctx *pulumi.Context, 255 name string, args *ExportTaskArgs, opts ...pulumi.ResourceOption) (*ExportTask, error) { 256 if args == nil { 257 return nil, errors.New("missing one or more required arguments") 258 } 259 260 if args.ExportTaskIdentifier == nil { 261 return nil, errors.New("invalid value for required argument 'ExportTaskIdentifier'") 262 } 263 if args.IamRoleArn == nil { 264 return nil, errors.New("invalid value for required argument 'IamRoleArn'") 265 } 266 if args.KmsKeyId == nil { 267 return nil, errors.New("invalid value for required argument 'KmsKeyId'") 268 } 269 if args.S3BucketName == nil { 270 return nil, errors.New("invalid value for required argument 'S3BucketName'") 271 } 272 if args.SourceArn == nil { 273 return nil, errors.New("invalid value for required argument 'SourceArn'") 274 } 275 opts = internal.PkgResourceDefaultOpts(opts) 276 var resource ExportTask 277 err := ctx.RegisterResource("aws:rds/exportTask:ExportTask", name, args, &resource, opts...) 278 if err != nil { 279 return nil, err 280 } 281 return &resource, nil 282 } 283 284 // GetExportTask gets an existing ExportTask resource's state with the given name, ID, and optional 285 // state properties that are used to uniquely qualify the lookup (nil if not required). 286 func GetExportTask(ctx *pulumi.Context, 287 name string, id pulumi.IDInput, state *ExportTaskState, opts ...pulumi.ResourceOption) (*ExportTask, error) { 288 var resource ExportTask 289 err := ctx.ReadResource("aws:rds/exportTask:ExportTask", name, id, state, &resource, opts...) 290 if err != nil { 291 return nil, err 292 } 293 return &resource, nil 294 } 295 296 // Input properties used for looking up and filtering ExportTask resources. 297 type exportTaskState struct { 298 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 299 ExportOnlies []string `pulumi:"exportOnlies"` 300 // Unique identifier for the snapshot export task. 301 ExportTaskIdentifier *string `pulumi:"exportTaskIdentifier"` 302 // Reason the export failed, if it failed. 303 FailureCause *string `pulumi:"failureCause"` 304 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 305 IamRoleArn *string `pulumi:"iamRoleArn"` 306 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 307 KmsKeyId *string `pulumi:"kmsKeyId"` 308 // Progress of the snapshot export task as a percentage. 309 PercentProgress *int `pulumi:"percentProgress"` 310 // Name of the Amazon S3 bucket to export the snapshot to. 311 S3BucketName *string `pulumi:"s3BucketName"` 312 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 313 S3Prefix *string `pulumi:"s3Prefix"` 314 // Time that the snapshot was created. 315 SnapshotTime *string `pulumi:"snapshotTime"` 316 // Amazon Resource Name (ARN) of the snapshot to export. 317 // 318 // The following arguments are optional: 319 SourceArn *string `pulumi:"sourceArn"` 320 // Type of source for the export. 321 SourceType *string `pulumi:"sourceType"` 322 // Status of the export task. 323 Status *string `pulumi:"status"` 324 // Time that the snapshot export task completed. 325 TaskEndTime *string `pulumi:"taskEndTime"` 326 // Time that the snapshot export task started. 327 TaskStartTime *string `pulumi:"taskStartTime"` 328 Timeouts *ExportTaskTimeouts `pulumi:"timeouts"` 329 // Warning about the snapshot export task, if any. 330 WarningMessage *string `pulumi:"warningMessage"` 331 } 332 333 type ExportTaskState struct { 334 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 335 ExportOnlies pulumi.StringArrayInput 336 // Unique identifier for the snapshot export task. 337 ExportTaskIdentifier pulumi.StringPtrInput 338 // Reason the export failed, if it failed. 339 FailureCause pulumi.StringPtrInput 340 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 341 IamRoleArn pulumi.StringPtrInput 342 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 343 KmsKeyId pulumi.StringPtrInput 344 // Progress of the snapshot export task as a percentage. 345 PercentProgress pulumi.IntPtrInput 346 // Name of the Amazon S3 bucket to export the snapshot to. 347 S3BucketName pulumi.StringPtrInput 348 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 349 S3Prefix pulumi.StringPtrInput 350 // Time that the snapshot was created. 351 SnapshotTime pulumi.StringPtrInput 352 // Amazon Resource Name (ARN) of the snapshot to export. 353 // 354 // The following arguments are optional: 355 SourceArn pulumi.StringPtrInput 356 // Type of source for the export. 357 SourceType pulumi.StringPtrInput 358 // Status of the export task. 359 Status pulumi.StringPtrInput 360 // Time that the snapshot export task completed. 361 TaskEndTime pulumi.StringPtrInput 362 // Time that the snapshot export task started. 363 TaskStartTime pulumi.StringPtrInput 364 Timeouts ExportTaskTimeoutsPtrInput 365 // Warning about the snapshot export task, if any. 366 WarningMessage pulumi.StringPtrInput 367 } 368 369 func (ExportTaskState) ElementType() reflect.Type { 370 return reflect.TypeOf((*exportTaskState)(nil)).Elem() 371 } 372 373 type exportTaskArgs struct { 374 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 375 ExportOnlies []string `pulumi:"exportOnlies"` 376 // Unique identifier for the snapshot export task. 377 ExportTaskIdentifier string `pulumi:"exportTaskIdentifier"` 378 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 379 IamRoleArn string `pulumi:"iamRoleArn"` 380 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 381 KmsKeyId string `pulumi:"kmsKeyId"` 382 // Name of the Amazon S3 bucket to export the snapshot to. 383 S3BucketName string `pulumi:"s3BucketName"` 384 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 385 S3Prefix *string `pulumi:"s3Prefix"` 386 // Amazon Resource Name (ARN) of the snapshot to export. 387 // 388 // The following arguments are optional: 389 SourceArn string `pulumi:"sourceArn"` 390 Timeouts *ExportTaskTimeouts `pulumi:"timeouts"` 391 } 392 393 // The set of arguments for constructing a ExportTask resource. 394 type ExportTaskArgs struct { 395 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 396 ExportOnlies pulumi.StringArrayInput 397 // Unique identifier for the snapshot export task. 398 ExportTaskIdentifier pulumi.StringInput 399 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 400 IamRoleArn pulumi.StringInput 401 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 402 KmsKeyId pulumi.StringInput 403 // Name of the Amazon S3 bucket to export the snapshot to. 404 S3BucketName pulumi.StringInput 405 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 406 S3Prefix pulumi.StringPtrInput 407 // Amazon Resource Name (ARN) of the snapshot to export. 408 // 409 // The following arguments are optional: 410 SourceArn pulumi.StringInput 411 Timeouts ExportTaskTimeoutsPtrInput 412 } 413 414 func (ExportTaskArgs) ElementType() reflect.Type { 415 return reflect.TypeOf((*exportTaskArgs)(nil)).Elem() 416 } 417 418 type ExportTaskInput interface { 419 pulumi.Input 420 421 ToExportTaskOutput() ExportTaskOutput 422 ToExportTaskOutputWithContext(ctx context.Context) ExportTaskOutput 423 } 424 425 func (*ExportTask) ElementType() reflect.Type { 426 return reflect.TypeOf((**ExportTask)(nil)).Elem() 427 } 428 429 func (i *ExportTask) ToExportTaskOutput() ExportTaskOutput { 430 return i.ToExportTaskOutputWithContext(context.Background()) 431 } 432 433 func (i *ExportTask) ToExportTaskOutputWithContext(ctx context.Context) ExportTaskOutput { 434 return pulumi.ToOutputWithContext(ctx, i).(ExportTaskOutput) 435 } 436 437 // ExportTaskArrayInput is an input type that accepts ExportTaskArray and ExportTaskArrayOutput values. 438 // You can construct a concrete instance of `ExportTaskArrayInput` via: 439 // 440 // ExportTaskArray{ ExportTaskArgs{...} } 441 type ExportTaskArrayInput interface { 442 pulumi.Input 443 444 ToExportTaskArrayOutput() ExportTaskArrayOutput 445 ToExportTaskArrayOutputWithContext(context.Context) ExportTaskArrayOutput 446 } 447 448 type ExportTaskArray []ExportTaskInput 449 450 func (ExportTaskArray) ElementType() reflect.Type { 451 return reflect.TypeOf((*[]*ExportTask)(nil)).Elem() 452 } 453 454 func (i ExportTaskArray) ToExportTaskArrayOutput() ExportTaskArrayOutput { 455 return i.ToExportTaskArrayOutputWithContext(context.Background()) 456 } 457 458 func (i ExportTaskArray) ToExportTaskArrayOutputWithContext(ctx context.Context) ExportTaskArrayOutput { 459 return pulumi.ToOutputWithContext(ctx, i).(ExportTaskArrayOutput) 460 } 461 462 // ExportTaskMapInput is an input type that accepts ExportTaskMap and ExportTaskMapOutput values. 463 // You can construct a concrete instance of `ExportTaskMapInput` via: 464 // 465 // ExportTaskMap{ "key": ExportTaskArgs{...} } 466 type ExportTaskMapInput interface { 467 pulumi.Input 468 469 ToExportTaskMapOutput() ExportTaskMapOutput 470 ToExportTaskMapOutputWithContext(context.Context) ExportTaskMapOutput 471 } 472 473 type ExportTaskMap map[string]ExportTaskInput 474 475 func (ExportTaskMap) ElementType() reflect.Type { 476 return reflect.TypeOf((*map[string]*ExportTask)(nil)).Elem() 477 } 478 479 func (i ExportTaskMap) ToExportTaskMapOutput() ExportTaskMapOutput { 480 return i.ToExportTaskMapOutputWithContext(context.Background()) 481 } 482 483 func (i ExportTaskMap) ToExportTaskMapOutputWithContext(ctx context.Context) ExportTaskMapOutput { 484 return pulumi.ToOutputWithContext(ctx, i).(ExportTaskMapOutput) 485 } 486 487 type ExportTaskOutput struct{ *pulumi.OutputState } 488 489 func (ExportTaskOutput) ElementType() reflect.Type { 490 return reflect.TypeOf((**ExportTask)(nil)).Elem() 491 } 492 493 func (o ExportTaskOutput) ToExportTaskOutput() ExportTaskOutput { 494 return o 495 } 496 497 func (o ExportTaskOutput) ToExportTaskOutputWithContext(ctx context.Context) ExportTaskOutput { 498 return o 499 } 500 501 // Data to be exported from the snapshot. If this parameter is not provided, all the snapshot data is exported. Valid values are documented in the [AWS StartExportTask API documentation](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_StartExportTask.html#API_StartExportTask_RequestParameters). 502 func (o ExportTaskOutput) ExportOnlies() pulumi.StringArrayOutput { 503 return o.ApplyT(func(v *ExportTask) pulumi.StringArrayOutput { return v.ExportOnlies }).(pulumi.StringArrayOutput) 504 } 505 506 // Unique identifier for the snapshot export task. 507 func (o ExportTaskOutput) ExportTaskIdentifier() pulumi.StringOutput { 508 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.ExportTaskIdentifier }).(pulumi.StringOutput) 509 } 510 511 // Reason the export failed, if it failed. 512 func (o ExportTaskOutput) FailureCause() pulumi.StringOutput { 513 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.FailureCause }).(pulumi.StringOutput) 514 } 515 516 // ARN of the IAM role to use for writing to the Amazon S3 bucket. 517 func (o ExportTaskOutput) IamRoleArn() pulumi.StringOutput { 518 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.IamRoleArn }).(pulumi.StringOutput) 519 } 520 521 // ID of the Amazon Web Services KMS key to use to encrypt the snapshot. 522 func (o ExportTaskOutput) KmsKeyId() pulumi.StringOutput { 523 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.KmsKeyId }).(pulumi.StringOutput) 524 } 525 526 // Progress of the snapshot export task as a percentage. 527 func (o ExportTaskOutput) PercentProgress() pulumi.IntOutput { 528 return o.ApplyT(func(v *ExportTask) pulumi.IntOutput { return v.PercentProgress }).(pulumi.IntOutput) 529 } 530 531 // Name of the Amazon S3 bucket to export the snapshot to. 532 func (o ExportTaskOutput) S3BucketName() pulumi.StringOutput { 533 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.S3BucketName }).(pulumi.StringOutput) 534 } 535 536 // Amazon S3 bucket prefix to use as the file name and path of the exported snapshot. 537 func (o ExportTaskOutput) S3Prefix() pulumi.StringOutput { 538 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.S3Prefix }).(pulumi.StringOutput) 539 } 540 541 // Time that the snapshot was created. 542 func (o ExportTaskOutput) SnapshotTime() pulumi.StringOutput { 543 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.SnapshotTime }).(pulumi.StringOutput) 544 } 545 546 // Amazon Resource Name (ARN) of the snapshot to export. 547 // 548 // The following arguments are optional: 549 func (o ExportTaskOutput) SourceArn() pulumi.StringOutput { 550 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.SourceArn }).(pulumi.StringOutput) 551 } 552 553 // Type of source for the export. 554 func (o ExportTaskOutput) SourceType() pulumi.StringOutput { 555 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.SourceType }).(pulumi.StringOutput) 556 } 557 558 // Status of the export task. 559 func (o ExportTaskOutput) Status() pulumi.StringOutput { 560 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.Status }).(pulumi.StringOutput) 561 } 562 563 // Time that the snapshot export task completed. 564 func (o ExportTaskOutput) TaskEndTime() pulumi.StringOutput { 565 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.TaskEndTime }).(pulumi.StringOutput) 566 } 567 568 // Time that the snapshot export task started. 569 func (o ExportTaskOutput) TaskStartTime() pulumi.StringOutput { 570 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.TaskStartTime }).(pulumi.StringOutput) 571 } 572 573 func (o ExportTaskOutput) Timeouts() ExportTaskTimeoutsPtrOutput { 574 return o.ApplyT(func(v *ExportTask) ExportTaskTimeoutsPtrOutput { return v.Timeouts }).(ExportTaskTimeoutsPtrOutput) 575 } 576 577 // Warning about the snapshot export task, if any. 578 func (o ExportTaskOutput) WarningMessage() pulumi.StringOutput { 579 return o.ApplyT(func(v *ExportTask) pulumi.StringOutput { return v.WarningMessage }).(pulumi.StringOutput) 580 } 581 582 type ExportTaskArrayOutput struct{ *pulumi.OutputState } 583 584 func (ExportTaskArrayOutput) ElementType() reflect.Type { 585 return reflect.TypeOf((*[]*ExportTask)(nil)).Elem() 586 } 587 588 func (o ExportTaskArrayOutput) ToExportTaskArrayOutput() ExportTaskArrayOutput { 589 return o 590 } 591 592 func (o ExportTaskArrayOutput) ToExportTaskArrayOutputWithContext(ctx context.Context) ExportTaskArrayOutput { 593 return o 594 } 595 596 func (o ExportTaskArrayOutput) Index(i pulumi.IntInput) ExportTaskOutput { 597 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *ExportTask { 598 return vs[0].([]*ExportTask)[vs[1].(int)] 599 }).(ExportTaskOutput) 600 } 601 602 type ExportTaskMapOutput struct{ *pulumi.OutputState } 603 604 func (ExportTaskMapOutput) ElementType() reflect.Type { 605 return reflect.TypeOf((*map[string]*ExportTask)(nil)).Elem() 606 } 607 608 func (o ExportTaskMapOutput) ToExportTaskMapOutput() ExportTaskMapOutput { 609 return o 610 } 611 612 func (o ExportTaskMapOutput) ToExportTaskMapOutputWithContext(ctx context.Context) ExportTaskMapOutput { 613 return o 614 } 615 616 func (o ExportTaskMapOutput) MapIndex(k pulumi.StringInput) ExportTaskOutput { 617 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *ExportTask { 618 return vs[0].(map[string]*ExportTask)[vs[1].(string)] 619 }).(ExportTaskOutput) 620 } 621 622 func init() { 623 pulumi.RegisterInputType(reflect.TypeOf((*ExportTaskInput)(nil)).Elem(), &ExportTask{}) 624 pulumi.RegisterInputType(reflect.TypeOf((*ExportTaskArrayInput)(nil)).Elem(), ExportTaskArray{}) 625 pulumi.RegisterInputType(reflect.TypeOf((*ExportTaskMapInput)(nil)).Elem(), ExportTaskMap{}) 626 pulumi.RegisterOutputType(ExportTaskOutput{}) 627 pulumi.RegisterOutputType(ExportTaskArrayOutput{}) 628 pulumi.RegisterOutputType(ExportTaskMapOutput{}) 629 }