2017 © Pedro Peláez
 

symfony-bundle assets-bundle

Implements image upload support for projects utilizing limit0/assets

image

limit0/assets-bundle

Implements image upload support for projects utilizing limit0/assets

  • Tuesday, March 7, 2017
  • by solocommand
  • Repository
  • 3 Watchers
  • 0 Stars
  • 228 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Limit0AssetsBundle

Implements image upload support for projects utilizing limit0/assets, (*1)

Requirements

  • You need an AWS account with access to an S3 bucket, or
  • You need write access via your web server user to a path for local storage.

Installation

Install the package via composer:, (*2)

composer require limit0/assets-bundle

Include the bundle in your AppKernel.php:, (*3)

    public function registerBundles()
    {
        $bundles = [
            // ...
            new Limit0\AssetsBundle\Limit0AssetsBundle(),
            // ...

Configuration

Configure the bundle using your preferred asset storage provider. Full possible configuration is listed below:, (*4)

limit0_assets:
    engine: aws_s3                              # Either `aws_s3` or `local_storage`
    http_prefix: //my-cdn.io/path-to-images/    # A URL prefix for your uploaded images. Can be relative.
    # The URL provided by the uploader will prefix the filename with this path, so they can be viewed.
    aws_s3:
        region: us-east-1                       # Default S3 storage region
        acl: public-read                        # Default ACL for uploaded files
        bucket: mybucket                        # Bucket to upload files to
    local_storage:
        path: /uploads/myproject                # Path on server to upload files to. Can be relative.

If using AWS S3, bucket is required. If using local storage, path is required., (*5)

Routing

You will need to import this bundle's routing. To prevent any potential collision issues, be sure to load it any other application routes:, (*6)


limit0_assets: resource: "@Limit0AssetsBundle/Resources/config/routing.yml" prefix: / app_bundle: resource: "@AppBundle/Resources/config/routing.yml" # ...

The Versions

07/03 2017

dev-master

9999999-dev

Implements image upload support for projects utilizing limit0/assets

  Sources   Download

MIT

The Requires

 

by Josh Worden

07/03 2017

v1.0

1.0.0.0

Implements image upload support for projects utilizing limit0/assets

  Sources   Download

MIT

The Requires

 

by Josh Worden