Fixed config path bugs in Docker
This commit is contained in:
parent
a4d29036c5
commit
cb539ad64d
@ -16,7 +16,7 @@ import threading
|
|||||||
import time
|
import time
|
||||||
import requests
|
import requests
|
||||||
|
|
||||||
CONFIG_PATH = os.environ.get('CONFIG_PATH', os.getcwd() + "/")
|
CONFIG_PATH = os.environ.get('CONFIG_PATH', os.getcwd())
|
||||||
|
|
||||||
|
|
||||||
class GracefulExit:
|
class GracefulExit:
|
||||||
@ -210,7 +210,7 @@ if __name__ == '__main__':
|
|||||||
|
|
||||||
config = None
|
config = None
|
||||||
try:
|
try:
|
||||||
with open(CONFIG_PATH + "config.json") as config_file:
|
with open(os.path.join(CONFIG_PATH, "config.json")) as config_file:
|
||||||
config = json.loads(config_file.read())
|
config = json.loads(config_file.read())
|
||||||
except:
|
except:
|
||||||
print("😡 Error reading config.json")
|
print("😡 Error reading config.json")
|
||||||
|
|||||||
Reference in New Issue
Block a user