1
1
mirror of https://github.com/chubin/cheat.sh.git synced 2024-11-29 23:36:40 +03:00

Set Redis host using cheat.sh config framework

f5d5fae712/lib/config.py
This commit is contained in:
Anatoli Babenia 2020-08-01 00:41:05 +03:00
parent ee273e2d51
commit 91320d921d
3 changed files with 5 additions and 3 deletions

View File

@ -14,4 +14,4 @@ script:
- curl http://localhost:8002 - curl http://localhost:8002
- docker-compose logs --no-color - docker-compose logs --no-color
- docker logs chtsh - docker logs chtsh
- REDIS_HOST=http://redis:6379 CHEATSH_TEST_STANDALONE=NO bash tests/run-tests.sh - CHEATSH_TEST_STANDALONE=NO bash tests/run-tests.sh

View File

@ -6,6 +6,8 @@ services:
container_name: chtsh container_name: chtsh
depends_on: depends_on:
- redis - redis
environment:
- CHEATSH_REDIS_HOST=redis
ports: ports:
- "8002:8002" - "8002:8002"
redis: redis:

View File

@ -2,10 +2,10 @@
# 1) start server: # 1) start server:
# without caching: # without caching:
# REDIS_HOST=None CHEATSH_PORT=50000 python bin/srv.py # CHEATSH_REDIS_HOST=None CHEATSH_PORT=50000 python bin/srv.py
# (recommended) # (recommended)
# with caching: # with caching:
# REDIS_PREFIX=TEST1 CHEATSH_PORT=50000 python bin/srv.py # CHEATSH_REDIS_PREFIX=TEST1 CHEATSH_PORT=50000 python bin/srv.py
# (for complex search queries + to test caching) # (for complex search queries + to test caching)
# 2) configure CHTSH_URL # 2) configure CHTSH_URL
# 3) run the script # 3) run the script