2014-02-27 16:00:05 +00:00
|
|
|
# redis-cli
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
> Opens a connection to a Redis server.
|
2014-02-27 16:00:05 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Connect to the local server:
|
2014-02-27 16:00:05 +00:00
|
|
|
|
|
|
|
`redis-cli`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Connect to a remote server:
|
2014-02-27 16:00:05 +00:00
|
|
|
|
|
|
|
`redis-cli -h {{host}}`
|
|
|
|
`redis-cli -h {{host}} -p {{port}}`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Specify a password:
|
2014-02-27 16:00:05 +00:00
|
|
|
|
2014-02-27 16:01:23 +00:00
|
|
|
`redis-cli -a {{password}}`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Executes Redis command:
|
2014-02-27 16:01:23 +00:00
|
|
|
|
2015-10-28 08:33:06 +00:00
|
|
|
`redis-cli {{redis command}}`
|