Skip to content

Commit

Permalink
Aligning variable names (#7)
Browse files Browse the repository at this point in the history
* adding variable consistency

* Updated ENV variables names

---------

Co-authored-by: vladvildanov <[email protected]>
  • Loading branch information
chayim and vladvildanov authored Jan 2, 2024
1 parent 9b28aab commit 30a1195
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ IMAGE=redislabs/redis:latest
RE_USERNAME=[email protected]
RE_PASS=12345
RE_CLUSTER_NAME=test
OSS_CLUSTER=false
DB_PORT=12000
RE_USE_OSS_CLUSTER=false
RE_DB_PORT=12000
4 changes: 2 additions & 2 deletions .github/workflows/modes/.env.oss_cluster
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ IMAGE=redislabs/redis:latest
[email protected]
RE_PASS=12345
RE_CLUSTER_NAME=test
OSS_CLUSTER=true
DB_PORT=6378
RE_USE_OSS_CLUSTER=true
RE_DB_PORT=6378
4 changes: 2 additions & 2 deletions .github/workflows/modes/.env.proxy
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ IMAGE=redislabs/redis:latest
[email protected]
RE_PASS=12345
RE_CLUSTER_NAME=test
OSS_CLUSTER=false
DB_PORT=6379
RE_USE_OSS_CLUSTER=false
RE_DB_PORT=6379
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export $(cat .env.credentials | xargs)

### Build RE cluster ###
By default, RE cluster supports single endpoint and relies on DMC proxy to calculate hash slot.
Multiple endpoints (OSS cluster mode) could be enabled by setting env variable `OSS_CLUSTER=true`.
Multiple endpoints (OSS cluster mode) could be enabled by setting env variable `RE_USE_RE_USE_OSS_CLUSTER=true`.

All standard RE ports available from your local network:

Expand Down
2 changes: 1 addition & 1 deletion create_db.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash

curl -u $RE_USERNAME:$RE_PASS -H "Content-type: application/json" \
-d '{"name": "db", "port": '$DB_PORT', "memory_size": 1273741824, "replication": false, "eviction_policy": "volatile-lru", "sharding": true, "shards_count": 3, "module_list": [{"module_args": "", "module_name": "ReJSON"},{"module_args": "", "module_name": "search"},{"module_args": "", "module_name": "timeseries"},{"module_args": "", "module_name": "bf"}], "oss_cluster": '$OSS_CLUSTER', "proxy_policy": "all-nodes", "shards_placement": "sparse", "shard_key_regex": [{"regex": ".*\\{(?<tag>.*)\\}.*"},{"regex": "(?<tag>.*)"}]}' \
-d '{"name": "db", "port": '$RE_DB_PORT', "memory_size": 1273741824, "replication": false, "eviction_policy": "volatile-lru", "sharding": true, "shards_count": 3, "module_list": [{"module_args": "", "module_name": "ReJSON"},{"module_args": "", "module_name": "search"},{"module_args": "", "module_name": "timeseries"},{"module_args": "", "module_name": "bf"}], "oss_cluster": '$RE_USE_RE_USE_OSS_CLUSTER', "proxy_policy": "all-nodes", "shards_placement": "sparse", "shard_key_regex": [{"regex": ".*\\{(?<tag>.*)\\}.*"},{"regex": "(?<tag>.*)"}]}' \
-k -X POST https://localhost:9443/v1/bdbs
12 changes: 6 additions & 6 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ services:
- RE_USERNAME=${RE_USERNAME}
- RE_PASS=${RE_PASS}
- RE_CLUSTER_NAME=${RE_CLUSTER_NAME}
- DB_PORT=${DB_PORT}
- OSS_CLUSTER=${OSS_CLUSTER}
- RE_DB_PORT=${RE_DB_PORT}
- RE_USE_RE_USE_OSS_CLUSTER=${RE_USE_RE_USE_OSS_CLUSTER}
volumes:
- "$PWD/setup_cluster.sh:/opt/setup_cluster.sh"
- "$PWD/create_db.sh:/opt/create_db.sh"
Expand All @@ -38,8 +38,8 @@ services:
- RE_USERNAME=${RE_USERNAME}
- RE_PASS=${RE_PASS}
- RE_CLUSTER_NAME=${RE_CLUSTER_NAME}
- DB_PORT=${DB_PORT}
- OSS_CLUSTER=${OSS_CLUSTER}
- RE_DB_PORT=${RE_DB_PORT}
- RE_USE_RE_USE_OSS_CLUSTER=${RE_USE_RE_USE_OSS_CLUSTER}
volumes:
- "$PWD/join_node.sh:/opt/join_node.sh"
networks:
Expand All @@ -61,8 +61,8 @@ services:
- RE_USERNAME=${RE_USERNAME}
- RE_PASS=${RE_PASS}
- RE_CLUSTER_NAME=${RE_CLUSTER_NAME}
- DB_PORT=${DB_PORT}
- OSS_CLUSTER=${OSS_CLUSTER}
- RE_DB_PORT=${RE_DB_PORT}
- RE_USE_RE_USE_OSS_CLUSTER=${RE_USE_RE_USE_OSS_CLUSTER}
volumes:
- "$PWD/join_node.sh:/opt/join_node.sh"
networks:
Expand Down

0 comments on commit 30a1195

Please sign in to comment.