def index_template_delete(name, hosts=None, profile=None):
 es = _get_instance(hosts, profile)
 try:
  result = es.indices.delete_template(name=name)
  if result.get('acknowledged', False):
   return True
 except elasticsearch.exceptions.NotFoundError:
  return None
 return None

def index_template_delete ( name , hosts = None , profile = None ) : es = _get_instance ( hosts , profile ) try : result = es . indices . delete_template ( name = name ) if result . get ( 'acknowledged' , False ) : return True except elasticsearch . exceptions . NotFoundError : return None return None
delete an index template along with its data cli example:: salt myminion elasticsearch .