From af8133560f3b66fdcf780ad900b8050f6530893a Mon Sep 17 00:00:00 2001 From: Eesaan Atluri <atlurie@uab.edu> Date: Mon, 21 Dec 2020 22:09:14 -0600 Subject: [PATCH] Create /data/user /data/scratch dirs if they don't exist If they already exist then it would just ignore. --- dir_verify.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dir_verify.py b/dir_verify.py index 0f0127e..23dd341 100644 --- a/dir_verify.py +++ b/dir_verify.py @@ -31,7 +31,7 @@ def dir_verify(ch, method, properties, body): else: if not path.exists(): # Make sure folder exists and with right permission - path.mkdir(mode=0o700) + path.mkdir(mode=0o700, parents=True, exist_ok=True) # Make sure ownership is correct shutil.chown(path, int(msg['uid']), int(msg['gid'])) -- GitLab