I'm having trouble with a Laravel 6 app on Azure. I'm using TCG/Navigator to build my admin interface. Everything's hunky-dory in local development, but when I push the code to my development site in Azure, items from the storage disk are unavailable. I see this as broken images in the Navigator admin panel.
It looks like Laravel's file storage requires a symlink to operate:
https://laravel.com/docs/6.x/filesystem#the-public-disk
but symlinks don't appear to be supported in Azure's Windows web apps. I need something else to map /public/storage to /storage/app/public.
I can create a new virtual directory, but that didn't solve the problem. I mapped "/storage" to "site\wwwroot\storage\app\public" but I'm still seeing broken images in the Navigator admin panel.
I found this issue in Navigator's repo:
https://github.com/the-control-group/voyager/issues/417#issuecomment-304525223
and it seems like just the fix I need, but it's not working, either.
I've added:
'azure' => [
'driver' => 'local',
'root' => storage_path('..\public\storage'),
'url' => env('APP_URL').'/storage',
'visibility' => 'public',
],
to filesystems.php. In voyager.php, I see:
'storage' => [
'disk' => env('FILESYSTEM_DRIVER', 'public'),
],
so to leave things as is (ie, working) in local dev, I've added an application setting to my web app:
FILESYSTEM_DRIVER, set to 'azure'
I know that my Azure web app is trying to use the azure filesystem because I initially forgot to push the updated code and my app told me it was missing.
So now I think my problem might be that I don't have the right values in the definition of the azure storage disk. Got any ideas? Or maybe suggestions on a different approach to try to get Laravel's file storage working on Azure?