revert, rq_worker is in a container..
@@ -10,7 +10,11 @@ def gpu_queue(options):
from vent.helpers.meta import GpuUsage
status = (False, None)
- path_dir = os.path.join(os.path.expanduser("~"), ".vent")
+
+ if os.path.isdir("/root/.vent"):
+ path_dir = "/root/.vent"
+ else:
+ path_dir = "/vent"
print("gpu queue", str(options))
print("gpu queue", str(GpuUsage(base_dir=path_dir+"/",
@@ -127,7 +131,7 @@ def gpu_queue(options):
return status
-def file_queue(path, template_path=".vent/", r_host="redis"):
+def file_queue(path, template_path="/vent/", r_host="redis"):
"""
Processes files that have been added from the rq-worker, starts plugins
that match the mime type for the new file.
@@ -151,7 +155,8 @@ def file_queue(path, template_path=".vent/", r_host="redis"):
configs = {}
logger = Logger(__name__)
- template_path = os.path.join(os.path.expanduser("~"), template_path)
+ if os.path.isdir("/root/.vent"):
+ template_path = "/root/.vent/"
try:
d_client = docker.from_env()
