Last active
November 14, 2017 03:46
-
-
Save georgegoh/1bac380095f9507112eb76e814341b6a to your computer and use it in GitHub Desktop.
Set up backup path for Elasticsearch
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
oc rsh `oc get po -l component=es --show-labels -o name|head -n 1` \ | |
curl --cacert /etc/elasticsearch/secret/admin-ca \ | |
--cert /etc/elasticsearch/secret/admin-cert \ | |
--key /etc/elasticsearch/secret/admin-key \ | |
-XPUT 'https://logging-es:9200/_snapshot/log_backup?pretty' -H 'Content-Type: application/json' -d' | |
{ | |
"type": "fs", | |
"settings": { | |
"location": "/elasticsearch/backup", | |
"compress": true | |
} | |
} | |
' | |
oc rsh `oc get po -l component=es --show-labels -o name|head -n 1` \ | |
curl --cacert /etc/elasticsearch/secret/admin-ca \ | |
--cert /etc/elasticsearch/secret/admin-cert \ | |
--key /etc/elasticsearch/secret/admin-key \ | |
-XGET 'https://logging-es:9200/_snapshot/log_backup?pretty' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment