Curator 4 cli removing index attributes

We run a lot of basic curator operations on many clusters and were very glad to see the curator_cli addition so we can avoid the overhead and complexity of managing a bunch of configuration files. One thing we haven't been able to do so far is to remove an allocation attribute. We have hot nodes demarcated with a node_type attribute set to hot. After 7 days we want to remove this requirement by setting the string to an empty value in the index. We can do this manually:

PUT /test-index/_settings
{
  "index.routing.allocation.require.node_type" : ""
}

When trying to do this with Curator it doesn't like being passed an empty value. And I can't seem to get around it:

[root@es-test ~]# curator_cli --host test-host --port 9204 allocation --key node_type --allocation_type require --value "" --filter_list '[{"filtertype": "pattern","kind": "regex","value": "test-index*"}]'
No value for "value" provided

I am aware I can use include and overwrite the value, but some nodes don't have any attributes at all which will exclude them. Any ideas?

Coincidentally, this was requested just today: https://github.com/elastic/curator/issues/906

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.