예제 #1
0
 /**
  * Bootstrap the application services.
  *
  * @return void
  */
 public function boot()
 {
     Storage::extend('ovh', function ($app, $config) {
         $client = new OVHClient($config);
         return new Filesystem(new OVHAdapter($client->getContainer()));
     });
 }
예제 #2
0
 /**
  * @param array $config
  * @return Flysystem
  */
 public function get(array $config)
 {
     $client = new OVHClient(['username' => $config['username'], 'password' => $config['password'], 'tenantId' => $config['tenant_id'], 'container' => $config['container'], 'region' => $config['region']]);
     return new Flysystem(new OVHAdapter($client->getContainer()));
 }