Skip to content

Instantly share code, notes, and snippets.

@arukaen
Created November 23, 2021 17:58
Show Gist options
  • Save arukaen/f71bc28269de511f624cc704eb846a8e to your computer and use it in GitHub Desktop.
Save arukaen/f71bc28269de511f624cc704eb846a8e to your computer and use it in GitHub Desktop.
Configuring repository-s3 for ElasticSearch/Kibana backups in GovCloud

Introduction

I hope this gist helps someone as it was a bit of a pain for me to get this working (I couldn't find any documentation on it). If you are using respository-s3 on an ElasticSearch cluster in AWS GovCloud, you will not be able to configure the repository because the Kibana UI does not show some of these options. The best way is to do it via cURL / elasticsearch api as follows:

curl -X PUT "localhost:9200/_snapshot/your_bucket_name?pretty" -H 'Content-Type: application/json' -d'
{
  "type": "s3",
  "settings": {
    "bucket": "your_bucket_name",
    "region": "us-gov-west-1",
    "endpoint": "s3.us-gov-west-1.amazonaws.com"
  }
}
'

Replace bucket, region, and endpoint with your personal values.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment