Skip to content

studiofact/git-webhooks

Repository files navigation

GitWebHooks Build Status

Простой автоматический деплой

Установка через composer

Используйте composer для управления зависимостями и установкой модуля

composer require citfact/git-webhooks

Пример использования

work_dir: ./
repo_name: author/test
script:
  - git reset --hard HEAD
  - git pull origin master
  - composer install -q
  - npm install
  - bower install
  - gulp dist
<?php

use Monolog\Logger;
use Monolog\Handler\StreamHandler;
use Citfact\GitWebHooks\WebHook\BitbucketWebHook;
use Citfact\GitWebHooks\Workflow;
use Citfact\GitWebHooks\DeployConfig;

$logger = new Logger('WebHook Channel');
$logger->pushHandler(new StreamHandler('./your.log'));

$webHook = new BitbucketWebHook(json_decode($_POST['payload'], true));
$deploy = new DeployConfig('./webhook.yml');

$workflow = new Workflow($webHook, $deploy, $logger);
$workflow->process();

About

Простой автоматический деплой

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages