Skip to content

Commit 3885875

Browse files
authored
Add ILM rule tags generated by mc to getBucketLifecycle response (#3369)
1 parent cf05d50 commit 3885875

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

api/user_buckets_lifecycle.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,12 @@ func getBucketLifecycle(ctx context.Context, client MinioClient, bucketName stri
102102
Value: tagData.Value,
103103
})
104104
}
105-
105+
if rule.RuleFilter.Tag.Key != "" {
106+
tags = append(tags, &models.LifecycleTag{
107+
Key: rule.RuleFilter.Tag.Key,
108+
Value: rule.RuleFilter.Tag.Value,
109+
})
110+
}
106111
rulePrefix := rule.RuleFilter.And.Prefix
107112

108113
if rulePrefix == "" {

0 commit comments

Comments
 (0)