php 华为云对象存储安装( obs 安装)

由于公司所有服务将会转到华为云,因此,以前用到的阿里云 oss 存储都要改为华为云 obs 存储。以下为如何在 laravel 下安装华为云 SDK 。

在项目 composer.json 所在目录执行以下命令

composer require obs/esdk-obs-php

可能遇到问题: guzzlehttp 版本不正确,可以根据提示,添加指定的 guzzlehttp 版本,如下:

composer require "guzzlehttp/guzzle:6.3.0"

monolog 版本不正确,可以根据提示,添加指定 monolog版本

以下为成功安装返回信息:

D:\ftfoolish\blog> composer require obs/esdk-obs-php
Using version ^3.1 for obs/esdk-obs-php
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 5 installs, 0 updates, 0 removals
  - Installing psr/http-message (1.0.1): Loading from cache
  - Installing guzzlehttp/promises (v1.3.1): Loading from cache
  - Installing guzzlehttp/psr7 (1.4.2): Loading from cache
  - Installing guzzlehttp/guzzle (6.3.0): Loading from cache
  - Installing obs/esdk-obs-php (3.1.3): Loading from cache
Package phpunit/phpunit-mock-objects is abandoned, you should avoid using it. No replacement was suggested.
Writing lock file
Generating optimized autoload files

小提示

如有侵权请邮件通知