0

ubuntu 18.4でLaravelプロジェクトを作成しています。

プロジェクトをアップロードし、/var/www/html/画像をアップロードしますhome/sun/download/

このコードを実行した後:

$imageName = "thumb_{$size}.{$extension}";
$routePath = $url . '/products/' . $product->id . '/';

Image::make($file->path())->resize($size, null, function ($constraint) {
            $constraint->aspectRatio();
        })->save($routePath, $imageName);

このエラーを表示:

"Can't write image data to path (/home/sun/download/products/2/)"

この問題を発行するにはどうすればよいですか?

4

1 に答える 1