2017 © Pedro Peláez
 

symfony-bundle b2backblaze-bundle

Symfony bundle for B2 Cloud Storage

image

kamilz/b2backblaze-bundle

Symfony bundle for B2 Cloud Storage

  • Saturday, June 17, 2017
  • by kamil
  • Repository
  • 1 Watchers
  • 3 Stars
  • 26 Installations
  • PHP
  • 0 Dependents
  • 1 Suggesters
  • 2 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

B2BackblazeBundle

This bundle is a Symfony2 wrapper for b2backblaze library, (*1)

About B2 Cloud Storage

B2 Cloud Storage is a cloud service for storing files in the cloud. Files are available for download at any time, either through the API or through a browser-compatible URL., (*2)

The documentation for B2 Cloud storage can be found at https://www.backblaze.com/b2/docs/., (*3)

Installation

The recommended way to install this bundle is through Composer., (*4)

Install Composer

curl -sS https://getcomposer.org/installer | php, (*5)

Add B2BackblazeBundle as a dependency

php composer.phar require "kamilz/b2backblaze-bundle":"dev-master"

Enable the bundle in the kernel

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new KamilZ\B2BackblazeBundle\B2BackblazeBundle(),
        // ...
    );
}

Add required configuration

##config.yml

b2_backblaze:
    account_id: YOUR_ID
    account_key: YOUR_ACCCOUNT_SECRET_KEY
    bucket_id: YOUR_BUCKET_ID
    bucket_region: 'https://fxxx.backblaze.com/file/YOUR_BUCKET_NAME/'
    timeout: 2000

Usage

Upload File:, (*6)

<?php
    (...)
    $b2 = $this->get("backblaze.b2");

    $b2->uploadFile("...test.png","test.png");
    //or
    $b2->uploadFileByContent($file,"test.png");
    (...)

Twig image filter:, (*7)

{# twig template #}
    (..)

    <img src="{{ app.user.avatar|b2 }}" alt="">

    (..)

License

This bundle is under the MIT license. See the complete license in the bundle:, (*8)

Resources/meta/LICENSE

The Versions

17/06 2017

dev-master

9999999-dev https://github.com/kamilZ

Symfony bundle for B2 Cloud Storage

  Sources   Download

MIT

The Requires

 

The Development Requires

symfony2 symfony storage b2

17/06 2017

v0.0.2

0.0.2.0 https://github.com/kamilZ

Symfony bundle for B2 Cloud Storage

  Sources   Download

MIT

The Requires

 

The Development Requires

symfony storage b2