You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
php artisan snipeit:restore fails with an error message (maybe only if there are additional files for models. I uploaded some pdf manuals and handbooks)
Reproduction steps
backup an existing instance
start the docker version of snipe-it
cp the backup zip-file to the container
exec into the container
run php artisan snipeit:restore
...
Expected behavior
php artisan snipeit:restore runs and restores without error message
Screenshots
No response
Snipe-IT Version
6.0.9
Operating System
docker
Web Server
whatever the docker version uses
PHP Version
whatever the docker version uses
Operating System
No response
Browser
No response
Version
No response
Device
No response
Operating System
No response
Browser
No response
Version
No response
Error messages
root@snipe-7545fb8ccc-zrm46:/var/www/html# php artisan snipeit:restore ~/snipe-it-2022-08-20-19-26-14.zip
...
Weird problem, here are file details? Array
(
[dest] => storage/private_uploads/assetmodels
[index] => 16
)
ErrorException
fopen(storage/private_uploads/assetmodels/assetmodels): failed to open stream: No such file or directory
at app/Console/Commands/RestoreFromBackup.php:304
300▕ foreach ($interesting_files as $pretty_file_name =>$file_details) {
301▕ $ugly_file_name = $za->statIndex($file_details['index'])['name'];
302▕ $fp = $za->getStream($ugly_file_name);
303▕ $this->info("Weird problem, here are file details? ".print_r($file_details,true));
➜ 304▕ $migrated_file = fopen($file_details['dest'].'/'.basename($pretty_file_name), 'w');
305▕ while(($buffer= fgets($fp, self::$buffer_size))!== false) {
306▕ fwrite($migrated_file, $buffer);
307▕ }
308▕ fclose($migrated_file);
1 app/Console/Commands/RestoreFromBackup.php:304
### Additional context
I manually mkdir storage/private_uploads/assetmodels and then it works.
The text was updated successfully, but these errors were encountered:
👋 Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
Debug mode
Describe the bug
php artisan snipeit:restore fails with an error message (maybe only if there are additional files for models. I uploaded some pdf manuals and handbooks)
Reproduction steps
...
Expected behavior
php artisan snipeit:restore runs and restores without error message
Screenshots
No response
Snipe-IT Version
6.0.9
Operating System
docker
Web Server
whatever the docker version uses
PHP Version
whatever the docker version uses
Operating System
No response
Browser
No response
Version
No response
Device
No response
Operating System
No response
Browser
No response
Version
No response
Error messages
The text was updated successfully, but these errors were encountered: