bilbofox/deploy

Simple deploy toolkit for projects.

Maintainers

Package info

github.com/BilboTav/Deploy

Type:tool

pkg:composer/bilbofox/deploy

Transparency log

Statistics

Installs: 4

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

0.1 2026-08-14 15:52 UTC

This package is auto-updated.

Last update: 2026-08-14 15:54:20 UTC


README

This is a simple deploy toolkit for projects using various strategies represented by different commands.

Installation:

composer require bilbofox/deploy

DeployByPack

This command packages specified project files into pack (archive) and then uploads it to remote storage. Then calls remote hook for processing uploaded pack - on remote app built from package.

Example of usage:

use Bilbofox\Deploy\DeployByPack;
use Bilbofox\Deploy\PackBuilder;
use League\Flysystem\Filesystem;

require __DIR__ . '/../vendor/autoload.php';

// ---------------------------------------------------------------------------
// Storage configuration

$storage = new Filesystem(...);

// ---------------------------------------------------------------------------
// Pack-builder configuration

$projectRootDir = '/path/to/project/root';

$deployInfo = 'Time: ' . date_create()->format('Y-m-d H:i:s') . "\n";
$deployInfo .= 'Git: ' . exec('git branch -v') . "\n";

$packBuilder = new PackBuilder($projectRootDir)
    ->include(['app', 'bin', 'vendor'])
    ->exclude(['app/secret.config'])
    ->excludeMasks(['.git'])
    ->addEmptyDirs(['temp', 'log'])
    ->addCustomFile('.deploy-info', $deployInfo);

// ---------------------------------------------------------------------------
// Deploy run

$deployByPack = new DeployByPack(
    deployUrl: 'https://my-remote-app.com/deploy/',
    remoteDeployTarget: 'www/projects/my-project',
    remotePacksDir: 'www/deploy/packs',
    storage: $storage,
    packBuilder: $packBuilder,
);
$deployByPack->useEchoOutput();
$deployByPack->run();

Notes:

  • Storage is object from library league/flysystem
  • PackBuilder is internal class for specifying project files to pack
  • Remote app using package bilbofox/deploy-remote must be running on the server where we're deploying a project