Hi, I've been 2 weeks try to solving this problem. In windows (using xampp) i manage to retrieve video files (MP4) from storage api and served to client using route :
Route::get('fileentry/get/{filename}', [
'as' => 'getentry', 'uses' => 'FileEntryController@get']);
and
public function get($filename){
$entry = Fileentry::where('filename', '=', $filename)->firstOrFail();
$file = Storage::disk('local')->get($entry->filename);
return (new Response($file, 200))
->header('Content-Type', $entry->mime);
}
but when i deploy to my server with nginx as webserver that turned out error 404.
My nginx conf based on laravel documentation and my storage path permission is 775 with user www-data and group www-data.
Please share if you have a solution to this problem.
PS : i used this Tutorial in here
Thanks :)
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community