Created
March 14, 2015 14:58
-
-
Save deeravenger/49edd74e601634257439 to your computer and use it in GitHub Desktop.
Selectel flysystem
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use OpenCloud\OpenStack; | |
use League\Flysystem\Filesystem; | |
use League\Flysystem\Rackspace\RackspaceAdapter; | |
$client = new OpenStack('https://auth.selcdn.ru', [ | |
'username' => '...', | |
'password' => '...' | |
]); | |
$store = $client->objectStoreService('swift', 'Common'); | |
$container = $store->getContainer('YOUR_CONTAINER_NAME'); | |
$filesystem = new Filesystem(new RackspaceAdapter($container)); | |
var_dump($filesystem->listContents()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment