Created
October 21, 2021 19:27
-
-
Save DaveRuijter/bb85ac7208d9057c69eae9ce7c10358d to your computer and use it in GitHub Desktop.
This policy is used on the storage account that contains the backup copies of the Data Lake. This will apply retention of 60 days to the weekly backups, and retention of 30 days to the daily (incremental) backups.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"rules": [ | |
{ | |
"enabled": true, | |
"name": "weeklybackupsrule", | |
"type": "Lifecycle", | |
"definition": { | |
"actions": { | |
"baseBlob": { | |
"delete": { | |
"daysAfterModificationGreaterThan": 60 | |
} | |
} | |
}, | |
"filters": { | |
"blobTypes": [ | |
"blockBlob" | |
], | |
"prefixMatch": [ | |
"weekly" | |
] | |
} | |
} | |
}, | |
{ | |
"enabled": true, | |
"name": "dailybackupsrule", | |
"type": "Lifecycle", | |
"definition": { | |
"actions": { | |
"baseBlob": { | |
"delete": { | |
"daysAfterModificationGreaterThan": 30 | |
} | |
} | |
}, | |
"filters": { | |
"blobTypes": [ | |
"blockBlob" | |
], | |
"prefixMatch": [ | |
"daily" | |
] | |
} | |
} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment