This file contains 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
[ david@samwise ] $ cat salt.sls | |
/etc/salt/minion: | |
file: | |
- managed | |
- owner: root | |
- group: root | |
- mode: 444 | |
- source: salt://salt/files/salt-minion.config | |
- template: jinja | |
- context: { |
This file contains 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
[ david@samwise ] $ cat salt.sls | |
/etc/salt/minion: | |
file: | |
- managed | |
- owner: root | |
- group: root | |
- mode: 444 | |
- source: salt://salt/files/salt-minion.config | |
- template: jinja | |
- context: |
This file contains 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
openjdk-6-jre: | |
pkg: | |
- installed | |
/tmp/elasticsearch.tar.gz: | |
file: | |
- managed | |
- source: https://github.com/downloads/elasticsearch/elasticsearch/elasticsearch-0.19.2.tar.gz | |
/tmp/servicewrapper.tar.gz: |
This file contains 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
#!/usr/bin/env python | |
import salt.cli.caller | |
import salt.config | |
import argparse | |
import sys | |
parser = argparse.ArgumentParser(description='Check if minions are online.') | |
parser.add_argument('hostname', help='The name of the minion to be checked') | |
args = parser.parse_args() |
This file contains 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
#!/usr/bin/env python | |
import salt.cli.caller | |
import salt.config | |
import argparse | |
import sys | |
import signal | |
class TimeoutException(Exception): | |
pass |
This file contains 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
#!/usr/bin/env bash | |
###############FUNCTIONS############ | |
function prepare { | |
#optimize the index | |
echo -n "Optimizing index $INDEX_NAME..." | |
curl -XPOST "$ADDRESS/$INDEX_NAME/_optimize" 2>/dev/null| grep 'failed":0' >/dev/null | |
if [ $? -eq 0 ]; then | |
echo "done" |