schema-tools 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +12 -0
- data/lib/schema_tools/new_alias.rb +0 -5
- data/lib/schema_tools/rake_tasks.rb +2 -2
- data/lib/schema_tools.rb +3 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9b0a1829a0042b9d9e031af29d3684bb90a52af86943de3b12b95f55c8c0ac0b
|
4
|
+
data.tar.gz: 4b6675502d201d507ba404becfd2f310278abb6bf5f00751916d56a5a65a1708
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3306dea2eb57653f934bc9f18c6cf646bc12f2a2dfb55b905b899f69fefb84381d074486cc3c6bad865b73b353dd5b1e1059c117b36f9ba62533ae69f76f0e3c
|
7
|
+
data.tar.gz: 120bf4d22a5f50b5c68e9830aa0b900e089cdf11883480c2448216906ca79b4351bd318c31e59d2e77d770a25081cc736dfcd59cc17eac1b5a744f0116be6831
|
data/README.md
CHANGED
@@ -15,6 +15,12 @@ Install this Ruby gem.
|
|
15
15
|
gem install schema-tools
|
16
16
|
```
|
17
17
|
|
18
|
+
Add (or edit) a file called `Rakefile` and add this line:
|
19
|
+
|
20
|
+
```ruby
|
21
|
+
require 'schema_tools'
|
22
|
+
```
|
23
|
+
|
18
24
|
### Configuration
|
19
25
|
|
20
26
|
Set the connection URL for your OpenSearch or Elasticsearch instance:
|
@@ -35,6 +41,12 @@ export OPENSEARCH_USERNAME=your_username
|
|
35
41
|
export OPENSEARCH_PASSWORD=your_password
|
36
42
|
```
|
37
43
|
|
44
|
+
### View available rake tasks
|
45
|
+
|
46
|
+
```sh
|
47
|
+
rake -T | grep " schema:"
|
48
|
+
```
|
49
|
+
|
38
50
|
### Download an existing schema
|
39
51
|
|
40
52
|
Run `rake schema:download` to download a schema from an existing alias or index:
|
@@ -6,11 +6,6 @@ require_relative 'settings_filter'
|
|
6
6
|
|
7
7
|
module SchemaTools
|
8
8
|
def self.new_alias(client:)
|
9
|
-
puts "Warning: This tool only supports migrating aliases."
|
10
|
-
puts "Create an alias for this index by running:"
|
11
|
-
puts "rake schema:alias"
|
12
|
-
puts "\nDownload this index schema anyway? Y/n"
|
13
|
-
|
14
9
|
choice = STDIN.gets&.chomp&.downcase
|
15
10
|
if choice.nil? || choice.empty? || choice == 'y' || choice == 'yes'
|
16
11
|
# User wants to proceed with creating a new alias
|
data/lib/schema_tools.rb
CHANGED