From 3b2e8c8d95101fafe8d31de09db30cbedd6f6f3b Mon Sep 17 00:00:00 2001 From: cupcakearmy Date: Sat, 16 Feb 2019 16:25:26 +0100 Subject: [PATCH] Default DB and session name --- .gitignore | 3 ++- app.py | 5 +++-- docker-compose.yml | 8 ++------ 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/.gitignore b/.gitignore index 0cffcb3..af3e06c 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -config.json \ No newline at end of file +config.json +data.db \ No newline at end of file diff --git a/app.py b/app.py index 2d79acc..0b35f0f 100644 --- a/app.py +++ b/app.py @@ -5,7 +5,8 @@ import json from src import InstaBot data = json.load(open('config.json')) +data['database_name'] = 'data.db' +data['session_file'] = 'data.session' bot = InstaBot(**data) -while True: - bot.new_auto_mod() \ No newline at end of file +bot.mainloop() \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 50b5137..8de8067 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,4 +1,4 @@ -version: '3.6' +version: '3' services: instabot: @@ -6,9 +6,5 @@ services: restart: always container_name: instabot volumes: - # To reset the DB delete and create the data.db file - # rm data.db; touch data.db; - # or - # cat /dev/null > data.db - - ./data.db:/app/follows_db.db + - ./data.db:/app/data.db - ./config.json:/app/config.json:ro \ No newline at end of file