devhelp/backup
最新稳定版本:0.1.0
Composer 安装命令:
composer require devhelp/backup
包简介
Create backups using many filesystems
关键字:
README 文档
README
Purpose
This component provides backup functionality.
It uses Flysystem component.
Instalation
composer require 'devhelp/backup:dev-master'
Usage
To set up connection between two Flysystem adapters please read documentation
Below you can find simple usage which creates backup between ftp location and locale filesystem:
use Devhelp\Backup\FlysystemBackupFactory;
use Devhelp\Backup\Notification\NullNotification;
use League\Flysystem\Filesystem;
use League\Flysystem\Adapter\Ftp as FtpAdapter;
use League\Flysystem\Adapter\Local as LocalAdapter;
$sourceFilesystem = new Filesystem(new FtpAdapter(array(
'host' => 'example.com',
'username' => 'user',
'password' => 'secret'
)));
$targetFilesystem = new Filesystem(new LocalAdapter('/target/directory'));
$nullNotification = new NullNotification();
$backupManager = (new FlysystemBackupFactory($sourceFilesystem, $targetFilesystem))->create($nullNotification);
$backupManager->runProcess();
统计信息
- 总下载量: 28
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-11-23