feat: Add MinIO storage support and update image URLs
All checks were successful
Deploy Production (merchbay.com) / deploy (push) Successful in 2m54s
All checks were successful
Deploy Production (merchbay.com) / deploy (push) Successful in 2m54s
- Implemented MinIO storage driver in AppServiceProvider for S3-compatible storage. - Added helper functions to generate MinIO URLs for files and images. - Updated filesystem configuration to include MinIO settings. - Modified site configuration to include MinIO URL. - Enhanced Docker Compose configuration for local development with MinIO. - Updated various Blade templates to use MinIO URLs for images instead of local paths. - Ensured all image references in views are now pointing to MinIO storage.
This commit is contained in:
@@ -765,8 +765,7 @@ class UserController extends Controller
|
||||
|
||||
$u = $UserModel->insertNewProductThumbnails($thumbs);
|
||||
// var_dump($thumbs);
|
||||
Storage::disk('sftp')->put($thumbnail, fopen($request->file('imgupload')[$i], 'r+')); //live
|
||||
//Storage::disk('localdir')->put($thumbnail, fopen($request->file('imgupload')[$i], 'r+'));
|
||||
Storage::disk('minio_crewsportswear')->put('images/' . $thumbnail, fopen($request->file('imgupload')[$i], 'r+'));
|
||||
// var_dump($s);
|
||||
}
|
||||
|
||||
@@ -938,8 +937,7 @@ class UserController extends Controller
|
||||
);
|
||||
|
||||
$u = $UserModel->insertNewProductThumbnails($thumbs);
|
||||
Storage::disk('sftp')->put($thumbnail, fopen($request->file('upload_images')[$i], 'r+')); //live
|
||||
//Storage::disk('localdir')->put($thumbnail, fopen($request->file('upload_images')[$i], 'r+'));
|
||||
Storage::disk('minio_crewsportswear')->put('images/' . $thumbnail, fopen($request->file('upload_images')[$i], 'r+'));
|
||||
|
||||
}
|
||||
|
||||
@@ -961,6 +959,8 @@ class UserController extends Controller
|
||||
unlink($storagePath . $file);
|
||||
}
|
||||
|
||||
Storage::disk('minio_crewsportswear')->delete('images/' . $file);
|
||||
|
||||
$i = $UserModel->deleteImageThumb('Id', $id);
|
||||
|
||||
return response()->json(array(
|
||||
|
||||
Reference in New Issue
Block a user