install_elasticsearch2.sh 357 B

1234567
  1. #!/bin/bash
  2. sudo apt-get autoremove --purge elasticsearch
  3. wget -qO - https://packages.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
  4. echo "deb http://packages.elastic.co/elasticsearch/2.x/debian stable main" | sudo tee -a /etc/apt/sources.list.d/elk.list
  5. sudo apt-get update && sudo apt-get install elasticsearch -y
  6. sudo service elasticsearch start