I am uploading a zip file which I then need to get extracted at the path with the same file name. So I have used the Chumper/Zipper and to achieve my task I have used the following code i.e.
$zipper->zip('storage/apps/'.$name)->extractTo('storage/apps/'.$name);
It throws an error Failed to create folders at zipper.php at 534, which states, i.e.,
`if (!$this->file->exists($dir) && !$this->file->makeDirectory($dir, 0755, true, true)) {
throw new \RuntimeException('Failed to create folders');`
I figured out that there must a permission issue, so I did
sudo chmod -R 755 /var/www/html/admin-panel/public/storage/apps/
Still got the same error, so I again tried the above command with 777 which is both read/write in the parent directory.
Still, the issue is not resolved.
Help will be appreciated. Thanx