Skip to content
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-ha: fix busybox-ash-ism in redis_liveness.sh #294

Merged
merged 3 commits into from
Aug 26, 2024

Conversation

bootc
Copy link
Contributor

@bootc bootc commented Aug 22, 2024

What this PR does / why we need it:

The ${response:0:7} syntax is non-POSIX and not understood by Debian's dash shell, so if a Debian-based Redis image is used the liveness check breaks on slaves. A case statement makes this check more legible anyway, in my opinion, and works in all the POSIX-compatible shells (busybox ash, dash, and bash).

Which issue this PR fixes

No issue created (yet).

Checklist

  • DCO signed
  • Chart Version bumped
  • (n/a) Variables are documented in the README.md
  • Title of the PR starts with chart name (e.g. [stable/mychartname])

The ${response:0:7} syntax is non-POSIX and not understood by Debian's
dash shell, so if a Debian-based Redis image is used the liveness check
breaks on slaves. A case statement makes this check more legible anyway,
in my opinion, and works in all the POSIX-compatible shells (busybox
ash, dash, and bash).

Signed-off-by: Chris Boot <bootc@bootc.net>
DandyDeveloper
DandyDeveloper previously approved these changes Aug 26, 2024
@DandyDeveloper
Copy link
Owner

@bootc Waiting on a separate PR to merge and I'll edit the chart patch to get the latest pushed out. Thank you!

@DandyDeveloper DandyDeveloper merged commit 56940ae into DandyDeveloper:master Aug 26, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants