forked from wal-g/wal-g
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add 6.2 support, add redis_cli.sh workaround (wal-g#1022)
* Add 6.2 support, add redis_cli.sh workaround * Update redis_cli.sh * Update redis_cli.sh
- Loading branch information
Showing
8 changed files
with
56 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#!/usr/bin/env bash | ||
# | ||
# All args passed to this script will be passed to "redis-cli .. --rdb -" | ||
# | ||
# This script - workaround with redis-cli >= 6.2 bug, when redis-cli tries to fsync /dev/stdout and exit with error | ||
# see https://github.com/redis/redis/pull/9135 | ||
# | ||
|
||
FILENAME=$(mktemp --suffix=redis-cli-stderr) | ||
redis-cli $@ --rdb - 2>$FILENAME | ||
exit_code=$? | ||
cat $FILENAME >&2 | ||
grep "Fail to fsync" $FILENAME | grep -q "Invalid argument" | ||
FAILED=$? | ||
rm $FILENAME; | ||
if [[ $exit_code -ne 0 ]] ; then | ||
test 0 -eq $FAILED || exit $exit_code | ||
fi | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"WALG_S3_PREFIX": "s3://dbaas/redis-backup/test_uuid/test_redis", | ||
"AWS_ACCESS_KEY_ID": "S3_ACCESS_KEY", | ||
"AWS_SECRET_ACCESS_KEY": "S3_SECRET_KEY", | ||
"AWS_ENDPOINT": "http://minio:9000", | ||
"AWS_S3_FORCE_PATH_STYLE": "true", | ||
|
||
"WALG_STREAM_CREATE_COMMAND": "/usr/bin/redis_cli.sh --rdb /dev/stdout", | ||
"WALG_STREAM_RESTORE_COMMAND": "cat > /data/dump.rdb", | ||
|
||
"WALG_SENTINEL_USER_DATA": "{\"key\": \"value\"}", | ||
|
||
"WALG_PGP_KEY_PATH": "/etc/wal-g/gpg-key.armor", | ||
"WALG_COMPRESSION_METHOD": "brotli", | ||
"WALG_DISK_RATE_LIMIT": "41943040", | ||
"WALG_NETWORK_RATE_LIMIT": "10485760", | ||
"WALG_LOG_LEVEL": "DEVEL", | ||
"WALG_UPLOAD_CONCURRENCY" : 1, | ||
|
||
"WALG_REDIS_PASSWORD": "password" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters