EFtpAssetManager extends CAssetManager for Yii 1.1, to allow the use of PHP's wrappers ftp:// or http:// to store the assets. This is useful in a webfarm scenario where the webserver is the frontend to a number of PHP FastCGI servers which in other way would need to store the assets in a central storage shared by NFS or some other shared filesystem, or in every server.
- Unpack or clone the extension to your extensions directory.
- Setup your FTP and HTTP servers in the machine which will serve the assets.
In the 'components' section of your main.php:
<?php
//...
'components' => [
// ...
'assetManager' => [
'class' => 'EFtpAssetManager',
'lockAssets' => true,
'lockPath' => '/var/assets',
'basePath' => 'ftp://login:password@assets.example.com/',
'baseUrl' => 'https://assets.example.com/',
],
// ...
],
Copyright © 2008 Rodolfo González González.
See the LICENSE file.