Laravel newbie here (shoutout to Brad Traversy).
I've managed to deploy my first Laravel app, but the images won't show up (=as well as other media files that are part of the CRUD functionality=storage folder is not linked properly).
Website URL
Repo URL
filesystems.php
'default' => env('FILESYSTEM_DISK', 'public'),
'disks' => [
'public' => [
'driver' => 'local',
'root' => storage_path('app/public'),
'url' => env('APP_URL').'/storage',
'visibility' => 'public',
'throw' => false,
],
]
What I've tried (maybe the implementation was poor so if you're 100% certain this should work, I'll try again):
1. Removed .gitignore /storage and included all the related files to allow linking on the server-side (the storage part of the formula is definitely uploaded to my git repo and should be synched with my heroku app)
2. Edited my composer.json script as advised here
"scripts": {
//other standard code here
"post-install-cmd": [
"ln -sr storage/app/public public/storage"
]
},
3. Executed both throuth CML and Procfile implementation
heroku run php artisan storage:link
4. Browsed other laracasts/SO forum entries
5. Browsed a bunch of other threads and guides, because it's extremely weird that this functionality is not covered in deployment guides I cross-referenced 1 2
6. Desperately clenched my fists
I do not want to just create a folder with the same name in public, I want it to be as close as possible to the real environment (I'm fine with heroku's ephemerial file structure since this is simply a portfolio project, setting up S3 is overdoing it for proof-of-concept)
Any advice would be much appreciated, I'm out of options at this point :(