mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
appsv2: for the dir/subdirs of data_dir, create parent folders if they don't exist
This commit is contained in:
parent
ec82facff6
commit
9a4267ffa4
1 changed files with 2 additions and 2 deletions
|
@ -955,12 +955,12 @@ class DatadirAppResource(AppResource):
|
|||
)
|
||||
shutil.move(current_data_dir, self.dir)
|
||||
else:
|
||||
mkdir(self.dir)
|
||||
mkdir(self.dir, parents=True)
|
||||
|
||||
for subdir in self.subdirs:
|
||||
full_path = os.path.join(self.dir, subdir)
|
||||
if not os.path.isdir(full_path):
|
||||
mkdir(full_path)
|
||||
mkdir(full_path, parents=True)
|
||||
|
||||
owner, owner_perm = self.owner.split(":")
|
||||
group, group_perm = self.group.split(":")
|
||||
|
|
Loading…
Add table
Reference in a new issue