Created
October 4, 2022 12:36
-
-
Save weyderfs/c6a02239dc5d165611c217a1232f80b5 to your computer and use it in GitHub Desktop.
Elastic ILM Template Policy to delete Index
This file contains hidden or 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
{ | |
"policy": { | |
"description": "Delete index after 8D.", | |
"default_state": "hot", | |
"states": [ | |
{ | |
"name": "hot", | |
"actions": [{ | |
"replica_count": { | |
"number_of_replicas": 3 | |
} | |
} | |
], | |
"transitions": [ | |
{ | |
"state_name": "delete", | |
"conditions": { | |
"min_index_age": "8d" | |
} | |
} | |
] | |
}, | |
{ | |
"name": "delete", | |
"actions": [ | |
{ | |
"delete": {} | |
} | |
], | |
"transitions": [] | |
} | |
], | |
"ism_template": [ | |
{ | |
"index_patterns": [ | |
"my-index-foo*" | |
], | |
"priority": 0 | |
} | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment