Create or update a snapshot repository Added in 0.0.0
IMPORTANT: If you are migrating searchable snapshots, the repository name must be identical in the source and destination clusters.
To register a snapshot repository, the cluster's global metadata must be writeable.
Ensure there are no cluster blocks (for example, cluster.blocks.read_only
and clsuter.blocks.read_only_allow_delete
settings) that prevent write access.
Path parameters
-
A repository name
Query parameters
-
master_timeout string
Explicit operation timeout for connection to master node
-
timeout string
Explicit operation timeout
-
verify boolean
Whether to verify the repository after creation
POST
/_snapshot/{repository}
curl \
-X POST http://api.example.com/_snapshot/{repository} \
-H "Content-Type: application/json" \
-d '{"uuid":"string","type":"azure","":{"":42.0,"compress":true,"client":"string","container":"string","base_path":"string","readonly":true,"location_mode":"string"}}'
Request examples
_types:azurerepository
{
"uuid": "string",
"type": "azure",
"": {
"": 42.0,
"compress": true,
"client": "string",
"container": "string",
"base_path": "string",
"readonly": true,
"location_mode": "string"
}
}
{
"uuid": "string",
"type": "gcs",
"": {
"": 42.0,
"compress": true,
"bucket": "string",
"client": "string",
"base_path": "string",
"readonly": true,
"application_name": "string"
}
}
{
"uuid": "string",
"type": "s3",
"": {
"": 42.0,
"compress": true,
"bucket": "string",
"client": "string",
"base_path": "string",
"readonly": true,
"server_side_encryption": true,
"canned_acl": "string",
"storage_class": "string"
}
}
{
"uuid": "string",
"type": "fs",
"": {
"": 42.0,
"compress": true,
"location": "string",
"max_number_of_snapshots": 42.0,
"readonly": true
}
}
{
"uuid": "string",
"type": "url",
"": {
"": 42.0,
"compress": true,
"http_max_retries": 42.0,
"http_socket_timeout": "string",
"max_number_of_snapshots": 42.0,
"url": "string"
}
}
{
"uuid": "string",
"type": "source",
"": {
"": 42.0,
"compress": true,
"delegate_type": "string",
"max_number_of_snapshots": 42.0,
"read_only": true
}
}
Response examples (200)
{
"acknowledged": true
}