Skip to content

Instantly share code, notes, and snippets.

@kumar-de
Last active September 8, 2024 06:48
Show Gist options
  • Save kumar-de/6ca3e7b1b7a93368e0992ea1de0ebd91 to your computer and use it in GitHub Desktop.
Save kumar-de/6ca3e7b1b7a93368e0992ea1de0ebd91 to your computer and use it in GitHub Desktop.
create dockerized Redis with password #docker #redis #password

set up Redis used between connector and Datahub for local testing

sudo docker run \
--name umati-redis \
-d \
-p 6379:6379 \
-e REDIS_PASSWORD=mypas \
redis sh \
-c 'exec redis-server --requirepass "$REDIS_PASSWORD"'

for setting password in runtime for Redis

inside redis-cli, enter

config set requirepass <password>

every operation (get, set etc) thereafter must be authenticated as follows:

auth <password>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment