[FIX]Rsync fix on non-regular files
This commit is contained in:
parent
413df9d7f7
commit
981366a1a3
@ -4,6 +4,7 @@ from zipfile import ZipFile, ZIP_DEFLATED
|
||||
from datetime import datetime
|
||||
from os import walk, unlink
|
||||
from os.path import join as osjoin
|
||||
from os.path import isfile
|
||||
from glob import glob
|
||||
|
||||
# Backup plan for Docker volumes
|
||||
@ -29,6 +30,7 @@ def zipdir(path, ziph):
|
||||
# ziph is zipfile handle
|
||||
for root, dirs, files in walk(path):
|
||||
for file in files:
|
||||
if isfile(file):
|
||||
ziph.write(osjoin(root, file))
|
||||
|
||||
f = ZipFile(zippath, 'w', ZIP_DEFLATED)
|
||||
|
Loading…
Reference in New Issue
Block a user