Closed ghost closed 1 year ago
Reproducible with the following configuration:
<?xml version="1.0" encoding="UTF-8"?>
<phpbu>
<backups>
<backup name="314-reproduction">
<source type="tar">
<option name="path" value="/this/path/does/not/exist"/>
</source>
<target dirname="/tmp/backup-target" filename="backup.tar" />
</backup>
</backups>
</phpbu>
➜ phpbu git:(main) ✗ ./phpbu --configuration=test-configuration.xml --debug
phpbu 6.0-dev by Sebastian Feldmann and contributors.
could not find directory to compress
I opened a pull request with a possible solution to this problem: https://github.com/sebastianfeldmann/phpbu/pull/325:
➜ phpbu git:(fix/314-tar-dir-not-exists) ✗ ./phpbu --configuration=test-configuration.xml --debug
phpbu 6.0-dev by Sebastian Feldmann and contributors.
backup: [tar] *************************************************************
exception: Could not find directory to compress at "/this/path/does/not/exist".
failed
Time: 1 second, Memory: 4.00MB
Exception 'phpbu\App\Exception' with message 'Could not find directory to compress at "/this/path/does/not/exist".'
in /Users/paik/Projects/phpbu/src/Backup/Source/Tar.php:332
FAILURE!
Backups: 1, failed Checks: 0, failed Crypts: 0, failed Syncs: 0, failed Cleanups: 0.
As mentioned above. No Error is send via smtp when following message gets triggered: "could not find directory to compress".