Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions internal/s3pmoxcommon/s3pmoxcommon.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,16 @@ func ListSnapshots(c minio.Client, datastore string, returnCorrupted bool) ([]Sn
corrupted: false,
}

tags, err := S.ReadTags(c)
if err == nil {
if val, ok := tags["protected"]; ok && val == "true" {
S.Protected = true
s3backuplog.DebugPrint("Snapshot %s marked as protected (from tags)", S.S3Prefix())
}
} else {
s3backuplog.DebugPrint("Unable to get tags for %s: %s", S.S3Prefix(), err)
}

if len(path) == 3 {
S.Files = append(S.Files, SnapshotFile{
Filename: path[2],
Expand Down