Download the PHP package bravesheep/flysystem-url-bundle without Composer
On this page you can find all versions of the php package bravesheep/flysystem-url-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download bravesheep/flysystem-url-bundle
More information about bravesheep/flysystem-url-bundle
Files in bravesheep/flysystem-url-bundle
Package flysystem-url-bundle
Short Description FlySystem URL bundle generates services for flysystem by specifying a url parameter
License MIT
Informations about the package flysystem-url-bundle
BravesheepFlysystemUrlBundle
A Symfony bundle that creates flysystem services based upon a url specified in the symfony configuration.
Installation and configuration
Using Composer add the bundle to your
dependencies using the require command:
composer require bravesheep/flysystem-url-bundle.
Add the bundle to your AppKernel
Add the bundle in your app/AppKernel.php. Note: in order for the
parameters defined by this bundle to be picked up by other bundles using
them you need to put it before those bundles. See below for more
information.
Configure the bundle
For this bundle you need to configure which urls should be used and what
the service names should be for the generated services. An example
configuration is shown below where the media_fs_url parameter (which
you can put in your parameters.yml for example) generates a
flysystem adapter service for you to use.
Accepted urls
Several url formats are accepted, a short overview of supported urls is shown below:
local:///path/to/directoryorfile:///path/to/directoryfor local filesystem storage. In case of local urls an absolute path is required. Use for example thekernel.root_dirparameter:file://%kernel.root_dir%/../web/media. Thelockquery parameter may be used to indicate different locking behavior:local:///path/to/directory?lock=false. Public file permissions may be set using thefile_permparameter:local:///path/to/directory?file_perm=0744. Similarly thefile_perm_private,dir_permanddir_perm_privateparameters are available.ftp://user:pass@host:port/path/to/dirfor FTP usage. Alternativelyftpsscheme may be used for SSL secured FTP.sftp://user:pass@host:port/path/to/dir?keyfile=path/to/keyfileor alternatively thesshscheme may be specified for the same behavior.dropbox://access_token:[email protected]for Dropbox access.s3://key:secret@region/bucketfor Amazon AWS S3. Alternatively theawss3andawss3v3schemes are available. For the v2 version of the AWS API you may useawss3v2as a scheme.null://or justnullmay be specified for a testing storage adapter which does not store anything.zip:///path/to/file.zipmay be used for local zip access.webdav://user:pass@host:port/path/to/dirmay be used for WebDAV access. Alternativelyhttp://user:pass@host:port/path/to/dirorhttps://user:pass@host:port/path/to/dirmay be used as well.
Extra variable encodings
By default this bundle does not just create a flysystem adapter service but can also generate some extra parameters which you can directly use.
The bundle by default generates a parameter you can use in the OneupFlysystemBundle as a value for your adapter:
By default the bundle also generates a public prefix url for some services if it can determine that url automatically. You could use this for example with the VichUploaderBundle:
If you don't need these parameters you can change them in the configuration of this bundle:
All versions of flysystem-url-bundle with dependencies
symfony/config Version ^2.3|^3.0
symfony/dependency-injection Version ^2.3|^3.0
symfony/http-kernel Version ^2.3|^3.0