April 6, 2018

Finally have a working prototype scaleset for Elasticesearch 1.7 running in Azure. Oddities:

  1. While the config trigger is being handled in terraform with a VM Extension, it still relies on a Bash script running in the context of the VM being created to set itself up.
  2. The config that’s executed by the VM Extension only approximates dynamic configuration by looping over some passed-in variables. Better than nothing, though.

Hopefully Consul will be able to address the service discovery concern, since right now the ES zen discovery addressing is dynamically hard-coded. It’s possible there’s a way to handle that “internally”, but so far I haven’t been able to find a way to access scaleset instance information during the startup process, and so am needing to gather that information in Bash when the VM starts up. #

TIL about Bash’s greedy variable parsing courtesy of krallja; this means that in the context of a Bash substitution varible like $host$prefix0000$counter, $prefix0000 is parsed as a whole variable instead of as a variable followed by a string. On the other hand in $host$prefix-0000$counter, $prefix is a variable since “-“ isn’t valid in a variable name. You can also resolve this like $host${prefix}0000$counter. #