尝试在Laravel应用中上传文件时出现AWS S3错误

时间:2019-01-09 15:57:35

标签: laravel amazon-s3

我正在尝试使用Laravel应用程序(在本地计算机上运行)设置S3,但是在尝试上传图像时出现以下错误。

$my_file = 'file.txt';
$handle = fopen($my_file, 'w') or die('Cannot open file:  '.$my_file);
$data = 'Test data to see if this works!';
fwrite($handle, $data);

$storagePath = Storage::disk('s3')->put("uploads", $my_file, 'public');

这是我得到的错误:

Error executing "PutObject" on "https://landlord-files.s3.eu-west-2.amazonaws.com/uploads"; AWS HTTP error: cURL error 60: SSL certificate problem: unable to get local issuer certificate (see http://curl.haxx.se/libcurl/c/libcurl-errors.html)

0 个答案:

没有答案