Skip to content

Commit

Permalink
Merge pull request #249 from irh-hdh/chore/wait-for-redis-script-redi…
Browse files Browse the repository at this point in the history
…ss-scheme

chore: 'check-redis.sh' script accounts for rediss:// scheme
  • Loading branch information
pierluigilenoci authored Oct 21, 2024
2 parents 9138c75 + 0750b72 commit 980e4d6
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
8 changes: 4 additions & 4 deletions helm/oauth2-proxy/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: oauth2-proxy
version: 7.7.27
version: 7.7.28
apiVersion: v2
appVersion: 7.7.1
home: https://oauth2-proxy.github.io/oauth2-proxy/
Expand Down Expand Up @@ -34,8 +34,8 @@ maintainers:
kubeVersion: ">=1.9.0-0"
annotations:
artifacthub.io/changes: |
- kind: fixed
description: Updated the Redis chart to the latest version.
- kind: added
description: Added support for 'rediss://' scheme in 'check-redis.sh' script
links:
- name: Github PR
url: https://github.com/oauth2-proxy/manifests/pull/247
url: https://github.com/oauth2-proxy/manifests/pull/249
11 changes: 10 additions & 1 deletion helm/oauth2-proxy/scripts/check-redis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,16 @@ check_redis() {
# For parsing and checking connections
parse_and_check() {
url=$1
clean_url=${url#redis://}

# Strip either redis:// or rediss://
if [[ $url == rediss://* ]]; then
clean_url=${url#rediss://}
echo "Using secure Rediss connection..."
else
clean_url=${url#redis://}
echo "Using standard Redis connection..."
fi

host=$(echo $clean_url | cut -d':' -f1)
port=$(echo $clean_url | cut -d':' -f2)
check_redis $host $port
Expand Down

0 comments on commit 980e4d6

Please sign in to comment.