GitS3\Wrapper\Bucket::upload PHP Method

upload() public method

public upload ( Symfony\Component\Finder\SplFileInfo $file )
$file Symfony\Component\Finder\SplFileInfo
    public function upload(File $file)
    {
        try {
            $this->client->putObject(array('Bucket' => $this->name, 'Key' => $file->getRelativePathname(), 'SourceFile' => $file->getRealpath(), 'ACL' => CannedAcl::PUBLIC_READ));
        } catch (InstanceProfileCredentialsException $e) {
            throw new InvalidAccessKeyIdException("The AWS Access Key Id you provided does not exist in our records.");
        }
    }