Skip to content

Instantly share code, notes, and snippets.

@jcantrill
Last active July 24, 2018 20:28
Show Gist options
  • Save jcantrill/ae4a3c017202ea91568926dd2365ad9a to your computer and use it in GitHub Desktop.
Save jcantrill/ae4a3c017202ea91568926dd2365ad9a to your computer and use it in GitHub Desktop.
#!/bin/bash
POD=$1
enable=${2:-"all"} #or none
PERSIST=${PERSIST:-"transient"}
oc exec -n logging -c elasticsearch $POD -- es_util --query=_cluster/settings -XPUT -d "{\"${PERSIST}\":{\"cluster.routing.allocation.enable\":\"${enable}\"}}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment