Spaces:
Sleeping
Sleeping
Scott Hiett
commited on
Commit
·
3bc171d
1
Parent(s):
ceb0280
Fix example indentation
Browse files
README.md
CHANGED
@@ -8,13 +8,13 @@
|
|
8 |
1) create a json file called tokens.json in a folder called srh-config (`srh-config/tokens.json`)
|
9 |
2) paste this in:
|
10 |
```json
|
11 |
-
|
12 |
"example_token": {
|
13 |
"srh_id": "some_unique_identifier",
|
14 |
"connection_string": "redis://localhost:6379",
|
15 |
"max_connections": 3
|
16 |
}
|
17 |
-
|
18 |
```
|
19 |
3) Run this command:
|
20 |
`docker run -it -d -p 8079:80 --name srh --mount type=bind,source=$(pwd)/srh-config/tokens.json,target=/app/srh-config/tokens.json hiett/serverless-redis-http:latest`
|
@@ -23,8 +23,8 @@
|
|
23 |
import {Redis} from '@upstash/redis';
|
24 |
|
25 |
export const redis = new Redis({
|
26 |
-
|
27 |
-
|
28 |
responseEncoding: false, // IMPORTANT: Upstash has recently added response encoding, but SRH does not support it yet.
|
29 |
});
|
30 |
```
|
|
|
8 |
1) create a json file called tokens.json in a folder called srh-config (`srh-config/tokens.json`)
|
9 |
2) paste this in:
|
10 |
```json
|
11 |
+
{
|
12 |
"example_token": {
|
13 |
"srh_id": "some_unique_identifier",
|
14 |
"connection_string": "redis://localhost:6379",
|
15 |
"max_connections": 3
|
16 |
}
|
17 |
+
}
|
18 |
```
|
19 |
3) Run this command:
|
20 |
`docker run -it -d -p 8079:80 --name srh --mount type=bind,source=$(pwd)/srh-config/tokens.json,target=/app/srh-config/tokens.json hiett/serverless-redis-http:latest`
|
|
|
23 |
import {Redis} from '@upstash/redis';
|
24 |
|
25 |
export const redis = new Redis({
|
26 |
+
url: "http://localhost:8079",
|
27 |
+
token: "example_token",
|
28 |
responseEncoding: false, // IMPORTANT: Upstash has recently added response encoding, but SRH does not support it yet.
|
29 |
});
|
30 |
```
|