aminueza / terraform-provider-minio

Terraform provider for managing MinIO S3 buckets and IAM Users.
https://registry.terraform.io/providers/aminueza/minio
GNU Affero General Public License v3.0
233 stars 69 forks source link

Add Noncurrent Version expiration to ilm policy #526

Closed ndejesus closed 10 months ago

ndejesus commented 11 months ago

Add Noncurrent Version expiration to ilm policy

This PR implements the following changes:

Adds noncurrentversionexpiration to minio_ilm_policy to support this option: Minio-go

New parameters will look like this:

resource "minio_ilm_policy" "bucket-lifecycle-rules" {
  bucket = minio_s3_bucket.bucket.bucket

  rule {
    id = "expire-noncurrentversion-7d"
    noncurrent_version_expiration_days = "7"
  }
}

Actually expired objects on versioned buckets are never deleted

Closing issues

ndejesus commented 10 months ago

Hi @pjsier, i take your remark into account. Please let me know if it's ok.

felladrin commented 10 months ago

That's great! Thanks for this addition, @ndejesus! And thanks, @pjsier, for reviewing it!