[release] sFTP backups for DirectAdmin (version: 0.1.poralix)

Active8

Verified User
Joined
Jul 13, 2013
Messages
466
Have a look at line 110 in the ftp_upload.php file and change .gz to .zst
Code:
FROM
cat ${DUMP} | grep -v '^sftp> ' | grep -E '(.*)\.tar(|\.gz)(|\.enc)$';

TO
cat ${DUMP} | grep -v '^sftp> ' | grep -E '(.*)\.tar(|\.zst)(|\.enc)$';

That will allow you to restore an account using DA backup/restore option. However, changing the code will only display .zst files and not many existing .gz.
Hi , I don't have any problems, it was more a request for the author to change his code on the github
Personally I don't think this is the right approach, I have altered ftp_list.php like:
Code:
cat ${DUMP} | grep -v '^sftp> ' | grep -E '(.*)\.tar(|\.zst)(|.gz)(|\.enc)$';
I can see al my backup extensions old and new one Tested with backup and recover and it works fine
 

LeonDynamic

Verified User
Joined
Sep 19, 2020
Messages
12
@Active8, my mistake I wrote ftp_upload.php in my reply and should have wrote ftp_list.php.

The approach used would depend entirely on whether you have older .gz backups or not. If you have both I would go with your approach.
 
Top