Home Arrow Icon Knowledge base Arrow Icon Global Arrow Icon How do I configure MediaMan to use a dedicated storage disk


How do I configure MediaMan to use a dedicated storage disk


To configure MediaMan to use a dedicated storage disk, you need to define a new disk in the `filesystems.php` configuration file and then update the `mediaman.php` configuration to use this disk. Here are the steps:

Step 1: Define a New Disk in `filesystems.php`

1. Open the `filesystems.php` configuration file in your Laravel project.
2. Add a new disk definition under the `disks` section:

php
   'disks' => [
       // Existing disks...
       'media' => [
           'driver' => 'local',
           'root' => storage_path('app/media'),
           'url' => env('APP_URL') . '/media',
           'visibility' => 'public',
       ],
   ],
   

Step 2: Update `mediaman.php` Configuration

1. Open the `mediaman.php` configuration file.
2. Update the `disk` configuration to use the newly defined `media` disk:

php
   'disk' => 'media',
   

Step 3: Create the Symbolic Link

1. Run the following command to create a symbolic link for the `media` disk:

bash
   php artisan storage:link
   

Step 4: Verify Configuration

1. After these steps, MediaMan should be configured to use the dedicated `media` disk for storing media files.

Additional Tips

- Ensure that the `media` disk is accessible by the MediaMan service provider. If you are using a network drive, you might need to configure the credentials for MediaMan to access it.
- You can customize the `media` disk further by adjusting the `root`, `url`, and `visibility` settings according to your needs.

By following these steps, you can configure MediaMan to use a dedicated storage disk for managing media files in your Laravel application.

Citations:
[1] https://documentation.commvault.com/2024/essential/configuring_disk_storage.html
[2] https://www.reddit.com/r/unRAID/comments/12ey0ps/best_configuration_for_drives_for_media_storage/
[3] https://github.com/FarhanShares/laravel-mediaman
[4] https://www.youtube.com/watch?v=zTD3wUgCp-c
[5] https://qsupport.quantum.com/kb/flare/Content/stornext/SN6_DocSite/Doc_Online_Help/Setting_Up_Storage_Disks.htm