-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
redis-stack-server docker startup script error #188
Comments
BTW why set REDISEARCH_ARGS to "MAXSEARCHRESULTS 10000 MAXAGGREGATERESULTS 10000" while these params are already hard coded in line 34 ? |
@zcw159357 There's a bunch of cruft there that we should really clean up. Thanks for this - it forced me to do it as part of the PR I'll link shortly. At one point an argument that is redeclared would win. But I recognize the confusion. Henceforth defaults will be set when none are set. As validation - here's the output of my docker (local) testing case, after building with a custom tag. Starting the docker: Yields: redis-cli
127.0.0.1:6379> ping
PONG
127.0.0.1:6379> module list
<snip>
3) 1) "name"
2) "search"
3) "ver"
4) (integer) 20411
5) "path"
6) "/opt/redis-stack/lib/redisearch.so"
7) "args"
8) 1) "MAXSEARCHRESULTS"
2) "5" Starting the docker without the search arguments: Yields: redis-cli
127.0.0.1:6379> ping
PONG
127.0.0.1:6379> module list
<snip>
2) 1) "name"
2) "search"
3) "ver"
4) (integer) 20411
5) "path"
6) "/opt/redis-stack/lib/redisearch.so"
7) "args"
8) 1) "MAXSEARCHRESULTS"
2) "10000"
3) "MAXAGGREGATERESULTS"
4) "10000" |
@chayim Thanks for replying. I get you'd like to set a default value for MAXSEARCHRESULTS and MAXAGGREGATERESULTS, what I didn't get is why bothering set value for REDISEARCH_ARGS in line 21,22,23 when REDISEARCH_ARGS is empty, isn't it already been done in line 34(old version)? And after #192 ,when starting with |
and.... the |
If you pass the variables in quoted, then it should be fine. So in the docker run -e REDISERACH_ARGS="FRISOINI ..." |
The idea is, if you're modifying these variables it's a series of known, desired choices. This was the issue with overrides.
This piece is... painful, admittedly. I prefer the "--thingyoucareabout value" syntax. However, in the case of a single argument from several locations we've had asks against it. I'm frankly, happy to walk that back - I don't love it, and feel that both choices are suboptimal. |
I don't think so..... It'll resulting in |
Ah, I see - yes the double quoting.. it's wrong. I'm going to reopen this, and the other associated bug; settle something for both. |
@zcw159357 Okay - I think we're fine here - with the current setup. Caveat: I am reverting the "--" but only for REDIS_ARGS. The trade here is that I've added documentation in the README. To validate, I ran the following, the upcoming change to reverse the "--" prefix on REDIS_ARGS.
Finally, I ran a variety of permutations:
In each case, the module arguments were validated via At this point, I think it's fair to call this closed. |
@chayim Sorry...but I still need to say....
quote the arg would be better right? |
Interesting; So I changed shells to see all sorts of output swallowed - thank you. I've added quotes to the REDISEARCH_ARGS, REDISGRAPH_ARGS args - as well as REDIS_DATA_DIR. For good measure, I'll hope no one uses this with the latter. I'll see if I can get this into today's release. |
@chayim Thanks for all the work! |
if set module args with space will cause entrypoint.sh report error msg.
like I set
and get
I checked the script and I think it may be better to surround ${REDISEARCH_ARGS} with " in the if judgment?
to
and I see #158 with same error, but not fixing the script.
The text was updated successfully, but these errors were encountered: