You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
800 B

7 years ago
# redis2json
7 years ago
`redis2json` is a simple _(dependency free!)_ lua script which runs directly in redis.
## usage
### export redis db to json file
redis-cli --eval redis2json.lua > /tmp/redis.json
### redis to couchdb
# create a couchdb database named "redis"
curl -X PUT
# export redis keys and import than in couchdb database "redis"
7 years ago
redis-cli --eval "redis2json.lua" | POST -sS "" -c "application/json"
7 years ago
## limitations
7 years ago
1. Currently redis2json only supports keys with `TYPE`
* `string`
* `list`
7 years ago
2. There are proper ways to get a json string from you redis db
* [rdb-rs](
* [redis-rdb-tools](
7 years ago
Feel free to help and improve it!