mirror of
https://github.com/adulau/napkin-text-analysis.git
synced 2024-11-24 19:07:08 +00:00
chg: [redis] use default Redis port
This commit is contained in:
parent
793ce3228f
commit
afc06a3850
2 changed files with 7 additions and 3 deletions
4
.github/workflows/python-app.yml
vendored
4
.github/workflows/python-app.yml
vendored
|
@ -15,6 +15,10 @@ jobs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- uses: zhulik/redis-action@1.1.0
|
||||||
|
with:
|
||||||
|
redis version: '5'
|
||||||
|
number of databases: 100
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Set up Python 3.8
|
- name: Set up Python 3.8
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v2
|
||||||
|
|
|
@ -39,14 +39,14 @@ if args.f is None:
|
||||||
# args.full_labels = True
|
# args.full_labels = True
|
||||||
|
|
||||||
if not args.binary:
|
if not args.binary:
|
||||||
redisdb = redis.Redis(host="localhost", port=6380, db=5, encoding='utf-8', decode_responses=True)
|
redisdb = redis.Redis(host="localhost", port=6379, db=5, encoding='utf-8', decode_responses=True)
|
||||||
else:
|
else:
|
||||||
redisdb = redis.Redis(host="localhost", port=6380, db=5)
|
redisdb = redis.Redis(host="localhost", port=6379, db=5)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
redisdb.ping()
|
redisdb.ping()
|
||||||
except:
|
except:
|
||||||
print("Redis database on port 6380 is not running...", file=sys.stderr)
|
print("Redis database on port 6379 is not running...", file=sys.stderr)
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
|
||||||
if not args.no_flushdb:
|
if not args.no_flushdb:
|
||||||
|
|
Loading…
Reference in a new issue