A deployment tool written in PHP with support for popular frameworks out of the box

Last update: Aug 7, 2022

Deployer Logo Deployer

A deployment tool written in PHP with support for popular frameworks out of the box.



Deployer Screenshot


Build Status Latest Stable Version License

See deployer.org for more information and documentation.

Contributing

Do you want to contribute to this project? Start working on one of those:

Maintainer

See also the list of contributors who participated in this project.

Sponsorship

  • Daniel Knoch

See a full list of sponsors.

Related

License

MIT

GitHub

https://github.com/deployphp/deployer
Comments
  • 1. Deployer unable to find composer installed recipes

    | Q | A | ----------------- | --- | Issue Type | Question | Deployer Version | 6.0.3 | Local Machine OS | WSL | Remote Machine OS | CentOS 7

    Description

    Deployer fails to find and require recipes installed via the method included in the third party recipe instructions

    Steps to reproduce

    Install recipes:

    composer require deployer/recipes --dev

    Add a recipe as per docs:

    require 'recipe/cachetool.php';

    Run deployment:

    dep deploy production OR php deployer.phar deploy production

    Result:

    PHP Warning:  require(recipe/cachetool.php): failed to open stream: No such file or directory in /mnt/d/web/deploy.php on line 3
    PHP Fatal error:  require(): Failed opening required 'recipe/cachetool.php' (include_path='phar:///mnt/d/web/deployer.phar/bin/../:.:/usr/share/php') in /mnt/d/web/blog.ib3.uk/deploy.php on line 3
    

    Content of deploy.php

    <?php
    namespace Deployer;
    
    require 'recipe/composer.php';
    require 'recipe/cachetool.php';
    
    // Project name
    set('application', 'Example');
    
    // Project repository
    set('repository', '[email protected]:foo');
    
    // Hosts
    host('xxx')
    	->stage('production')
    	->user('deploy')
        ->set('deploy_path', '/var/www')
        ->set('cachetool', '127.0.0.1:9000');
    
    // Shared files/dirs between deploys
    add('shared_dirs', [
    	'web/app/upgrade',
    	'web/app/uploads',
    	'web/app/wfcache',
    	'web/app/wflogs'
    ]);
    
    // Copy config
    task('enable_prod_config', function() {
    	run('cp "{{release_path}}/.env.prod" "{{release_path}}/.env"');
    })->onStage('production');
    after('deploy:update_code', 'enable_prod_config');
    
    // Clear opcache
    after('deploy:symlink', 'cachetool:clear:opcache');
    
    // [Optional] Allocate tty for git clone. Default value is false.
    set('git_tty', true);
    
    // [Optional] if deploy fails automatically unlock.
    after('deploy:failed', 'deploy:unlock');
    

    Worked around the issue thus:

    ini_set('include_path', ini_get('include_path') . PATH_SEPARATOR . 'vendor/deployer/recipes');
    

    Should that be part of the documtation or is something broken?

    Reviewed by jamieburchell at 2017-09-22 22:56
  • 2. Deprecate phpseclib, ext-ssh2 πŸ¦‹

    | Q | A | ----------------- | --- | Issue Type | Feature Request | Deployer Version | 5.x

    Now Deployer have 3 different implementations of ssh client: phpseclib, ext-ssh2 and native. I suggest deprecate first two and leave only native implementation with ssh multiplexing turned on by default. Reasons for then is what phpseclib and ext-ssh2 comes with different features and some may work in one, but not in another (like agent forwarding, ssh config, etc.). Also we need to support this three times of ssh libs. It will really simpler in there will be only one: native one. As it will come with all functionality. Also with ssh multiplexing it comes with same speed as phpseclib and ext-ssh2.

    Reviewed by antonmedv at 2017-01-26 06:51
  • 3. Phar problems: crc32 mismatch on file

    I'm having some issues with deployer connections. When I try to php ./vendor/bin/dep ssh test it fails 50% of the time. This is both on my local machine running Arch as well on my Gitlab server in CI/CD. Php version is 8.0.7 on Arch, 8.0.5 on the alpine based docker image used for CI/CD in Gitlab.

    • Deployer version: 7.0.0-beta.23
    • Deployment OS: ubuntu (docker container) / archlinux

    In testing I have reduced my deploy.yaml to a minimal setup like this:

    config:
      application: APPNAME
      user: USER
      host: HOST
      base_deploy_path: "~/domains"
      repository: "REPONAME"
    
    hosts:
      test:
        remote_user: "{{user}}"
        hostname: "{{host}}"
        deploy_path: "{{base_deploy_path}}/APPLICATION_URL"
    

    This is what I get when the CD fails with this issue:

    $ php ./vendor/bin/dep deploy test
    In ClassLoader.php line 444:
                                                                                   
      include(phar:///builds/APPLICATION_NAME/vendor/deployer/dist/dep/vendor/com  
      poser/../../src/Selector/Selector.php): Failed to open stream: phar error:   
      internal corruption of phar "/builds/APPLICATION_NAME/vendor/deployer/dist/  
      dep" (crc32 mismatch on file "src/Selector/Selector.php")                    
                                                                                   
    deploy [--tag TAG] [--revision REVISION] [--branch BRANCH] [-o|--option OPTION] [-l|--limit LIMIT] [--no-hooks] [--plan] [--start-from START-FROM] [--log LOG] [--profile PROFILE] [--] [<selector>...]
    

    The application server is running OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017. I could try to have that updated to a newer build as it seems a bit old to me.

    Reviewed by coffeeneer at 2021-06-25 20:33
  • 4. Sudo and PTY mode

    | Q | A | ----------------- | --- | Issue Type | Bug | Deployer Version | 4.3 | Local Machine OS | Linux work 3.13.0-37-generic #64-Ubuntu SMP Mon Sep 22 21:28:38 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux | Remote Machine OS | Linux release 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1 (2015-05-24) x86_64 GNU/Linux

    Description

    After commit https://github.com/deployphp/deployer/commit/157a8d0d78a542339407afd8a3b1c5a4187be3c2 deploy always wait

    It reproduced on 2 different dev PC and 2 different servers

    Without pty option all works fine, but sudo not

    Steps to reproduce

    Im add echo to this place and get full command

    Before commit changes:

    $ ./vendor/bin/dep date production -vvv
    ➀ Executing task date
    [production] > date
    Execute: ssh -A -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o ControlMaster=auto -o ControlPersist=5 -o ControlPath='~/.ssh/[email protected]_IP:22' -p '22' -i '/home/vlad/.ssh/id_rsa' -t '[email protected]_IP' 'date'[production] < Fri Apr  7 10:23:16 EDT 2017
    [production] < Shared connection to SOME_IP closed.
    β€’ done on [production]
    βœ” Ok [147ms]
    

    After commit changes:

    $ ./vendor/bin/dep date production -vvv
    ➀ Executing task date
    [production] > date
    Execute: ssh -A -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o ControlMaster=auto -o ControlPersist=5 -o ControlPath='~/.ssh/[email protected]_IP:22' -p '22' -i '/home/vlad/.ssh/id_rsa' -t '[email protected]_IP' bash -s
    

    and wait

    Content of deploy.php

    <?php
    namespace Deployer;
    
    require 'recipe/common.php';
    
    // Configuration
    
    set('ssh_type', 'native');
    set('ssh_multiplexing', true);
    
    set('repository', 'https://github.com/user/repo.git');
    set('shared_files', []);
    set('shared_dirs', []);
    set('writable_dirs', []);
    
    // Servers
    
    task('date', function () {
        run("date");
    });
    
    server('production', 'SOME_IP')
        ->user('deployer')
        ->identityFile()
        ->stage('production')
        ->set('deploy_path', '/home/deployer/test')
        ->pty(true);
    
    Reviewed by vladdnepr at 2017-04-07 14:30
  • 5. Getting stuck on dep:prepare

    | Q | A | ----------------- | --- | Issue Type | Question | Deployer Version | 6.8.0 | Local Machine OS | macOS 11.1 (Desktop) | Remote Machine OS | Ubuntu 20.04 (Server)

    Description

    I'm starting to play with deployer and wanted to see how it's gonna work. Unfortunately it does not, getting stuck on "echo $0".

    I commented the after at the end to get the error before the error at the deploy:unlock task.

    Content of deploy.php

    I use standard recipe with following configuration

    <?php
    
    namespace Deployer;
    
    require 'recipe/common.php';
    
    set('application', 'Secrets');
    set('repository', 'https://github.com/Luca-Castelnuovo/secrets.git');
    
    set('git_tty', true);
    set('allow_anonymous_stats', false);
    
    host('REDACTED_IP_ADDR')
        ->stage('production')
        ->user('webserver')
        ->set('deploy_path', '~/test');
    
    desc('Deploy your project');
    task('deploy', [
        'deploy:info',
        'deploy:prepare',
        'deploy:lock',
        'deploy:release',
        'deploy:update_code',
        'deploy:shared',
        'deploy:writable',
        'deploy:vendors',
        'deploy:clear_paths',
        'deploy:symlink',
        'deploy:unlock',
        'cleanup',
        'success',
    ]);
    
    // after('deploy:failed', 'deploy:unlock');
    

    Output log

    Screenshot 2021-01-16 at 18 41 09-redacted_dot_app

    Reviewed by Luca-Castelnuovo at 2021-01-16 17:46
  • 6. Allow Symfony 4.0 in composer.json

    | Q | A | ------------- | --- | Bug fix? | No | New feature? | No | BC breaks? | No | Deprecations? | No | Fixed tickets | N/A

    #SymfonyConHackday2017

    Do not forget to add notes about your changes to CHANGELOG.md

    • Add description under added/changed/fixed section.
    • Add reference to closed issues [#000].
    • Add link to issue in the end of document.
    Reviewed by pgodel at 2017-11-18 13:28
  • 7. Refactoring/Cleanup/Fixes for Symfony-related Recipes

    | Q | A | | --- | --- | | Bug fix? | Yes | | New feature? | Yes | | BC breaks? | Yes | | Deprecations? | No | | Fixed tickets | N/A |

    • Removed overridden deploy:assetic:dump task in symfony3 recipe, as it implied this command was no longer valid and should be overridden with deploy:assets:install command. In reality, deploy:assets:install should exist in all symfony versions, as should deploy:assetic:dump (although this is arguable, as deploy:assetic:dump isn't a Symfony command, it is a kriswallsmith/assetic command).
    • Changed default for deploy:assetic:dump to false (via dump_assets) as this is not a core Symfony package and should not be assumed to be installed. It relies on kriswallsmith/assetic and symfony/assetic-bundle.
    • Added deploy:assets:install task as this is a symfony-core command that is intended to be called prior to other asset compilation commands (such as deploy:assetic:dump). Its purpose to is to install any bundle assets (within <bundleName>/Resource/public) and put them in web/bundles/<bundleName>.
    • composer_action created
    • Fixed SYMFONY_ENV value in env_vars to correctly refer to the configured env value.
    • Created bin/console to cleanup calls to Symfony console command (there was a ton of duplicated lines prior)
    • created console_options so the options passed to bin/console reflect what should be passed per the configured environment (for example, the --no-debug options cannot be passed for any environment except for prod and will likely break hard when passed for dev environment)
    • General cleanup...
    Reviewed by robfrawley at 2016-06-05 17:17
  • 8. Creating extension/addon/plugin/shared recipe for Deployer

    | Q | A | ----------------- | --- | Issue Type | Question | Deployer Version | N/A | Local Machine OS | N/A | Remote Machine OS | N/A

    Description

    What is best practice for creating "shareable" recipes or extensions for Deployer? We would like to include some common tasks and other functionality between several of our applications.

    It seems that the deploy.php file is loaded within the context of the PHAR (or vendor if installed via composer?). So if we installed a composer package with custom tasks what would the require path need to be?

    Thank you.

    Reviewed by coreyworrell at 2018-12-04 01:49
  • 9. Git clone fails with ssh multiplexing

    | Q | A | ----------------- | --- | Issue Type | Question | Deployer Version | 4.2.1 | Local Machine OS | OSX Sierra | Remote Machine OS | Ubuntu 16.04

    Description

    When I run the deploy.php script it fails on the git clone command. If I run the command that you get from the error output the command is successful.

    Steps to reproduce

    1. run: php vendor/bin/dep install:production -vvv
    2. copy failed command from error output
    3. past en run command in terminal

    example command: ssh -A -q -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o ControlMaster=auto -o ControlPersist=5 -o ControlPath='~/.ssh/deployer_mux_s [email protected]:22' -p '22' -i '/Users/sander/.ssh/[email protected]' '[email protected]' 'cd www && (git clone [email protected]:sanderlissenburg/movi es-api.git)'

    Content of deploy.php

    <?php
    
    namespace Deployer;
    
    require 'recipe/common.php';
    
    set('ssh_type', 'native');
    set('ssh_multiplexing', true);
    set('default_stage', 'production');
    
    // I anonymised my ip adress
    server('production', '37.97.xxx.xx')
        ->user('sander')
        ->identityFileAndPassword('~/.ssh/[email protected]', '~/.ssh/[email protected]', null, null)
        ->stage('production')
    ;
    
    
    task('install:production', function() {
        writeln('<info>Deploying...</info>');
        cd('www');
        $response = run('pwd');
        writeln($response);
    
        // I know this is not the best way to do a clone with deployer
        $response = run('git clone [email protected]:sanderlissenburg/movies-api.git');
    });
    
    

    Output log

    [production] < /home/sander/www
    /home/sander/www
    
    [production] > cd www && (git clone [email protected]:sanderlissenburg/movies-api.git)
      SSH multiplexing initialization
    
    
      [Symfony\Component\Process\Exception\ProcessFailedException]
      The command "ssh -A -q -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o ControlMaster=auto -o ControlPersist=5 -o ControlPath='~/.ssh/deployer_mux_s
      [email protected]:22' -p '22' -i '/Users/sander/.ssh/[email protected]' '[email protected]' 'cd www && (git clone [email protected]:sanderlissenburg/movi
      es-api.git)'" failed.
      Exit Code: 128(Invalid exit argument)
      Working directory: /Users/sander/docker/www/movies-api
      Output:
      ================
      Error Output:
      ================
      Cloning into 'movies-api'...
      Permission denied (publickey).
      fatal: Could not read from remote repository.
      Please make sure you have the correct access rights
      and the repository exists.
    
    
    Exception trace:
     () at /Users/sander/docker/www/movies-api/vendor/symfony/symfony/src/Symfony/Component/Process/Process.php:233
     Symfony\Component\Process\Process->mustRun() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/Server/Remote/NativeSsh.php:87
     Deployer\Server\Remote\NativeSsh->run() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/functions.php:310
     Deployer\run() at /Users/sander/docker/www/movies-api/deploy.php:25
     Deployer\{closure}() at n/a:n/a
     call_user_func() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/Task/Task.php:85
     Deployer\Task\Task->run() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/Executor/SeriesExecutor.php:40
     Deployer\Executor\SeriesExecutor->run() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/Console/TaskCommand.php:95
     Deployer\Console\TaskCommand->execute() at /Users/sander/docker/www/movies-api/vendor/symfony/symfony/src/Symfony/Component/Console/Command/Command.php:262
     Symfony\Component\Console\Command\Command->run() at /Users/sander/docker/www/movies-api/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:826
     Symfony\Component\Console\Application->doRunCommand() at /Users/sander/docker/www/movies-api/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:189
     Symfony\Component\Console\Application->doRun() at /Users/sander/docker/www/movies-api/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:120
     Symfony\Component\Console\Application->run() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/src/Deployer.php:186
     Deployer\Deployer->run() at /Users/sander/docker/www/movies-api/vendor/deployer/deployer/bin/dep:114
    
    install:production [-p|--parallel]
    
    Reviewed by sanderfreshheads at 2017-02-18 16:21
  • 10. Deployment failing during deploy:vendors

    | Q | A | ----------------- | --- | Issue Type | Bug | Deployer Version | 4.3.0 | Local Machine OS | Ubuntu 16.04 | Remote Machine OS | Ubuntu 16.04

    Description

    Deployment up until deploy:vendors is successful. When I run the ssh command shown in the exception output, I receive the same error output with a blinking cursor Warning: Permanently added '162.13.127.83' (ECDSA) to the list of known hosts.

    Steps to reproduce

    Content of deploy.php

    <?php
    namespace Deployer;
    require 'recipe/common.php';
    
    // Configuration
    
    set('ssh_type', 'native');
    set('ssh_multiplexing', false);
    
    set('repository', '[email protected]:daykinstorey/blizzard-2017.git');
    set('shared_files', []);
    set('shared_dirs', []);
    set('writable_dirs', []);
    
    // Servers
    server('production', '162.13.127.83')
        ->forwardAgent()
    //    ->identityFile('/home/vagrant/.ssh/blizzard.pub', '/home/vagrant/.ssh/blizzard')
        ->set('deploy_path', '~/webapps/theblizzardtest');
    
    // Tasks
    desc('Restart PHP-FPM service');
    task('php-fpm:restart', function () {
        // The user must have rights for restart service
        // /etc/sudoers: username ALL=NOPASSWD:/bin/systemctl restart php-fpm.service
        run('sudo systemctl restart php71rc-fpm.service');
    });
    after('deploy:symlink', 'php-fpm:restart');
    
    desc('Deploy your project');
    task('deploy', [
        'deploy:prepare',
        'deploy:lock',
        'deploy:release',
        'deploy:update_code',
        'deploy:shared',
        'deploy:writable',
        'deploy:vendors',
        'deploy:clear_paths',
        'deploy:symlink',
        'deploy:unlock',
        'cleanup',
        'success'
    ]);
    
    // [Optional] if deploy fails automatically unlock.
    after('deploy:failed', 'deploy:unlock');
    

    Output log

    [email protected]:~/blizzard-dev$ vendor/bin/dep deploy production -vvv
    ➀ Executing task deploy:prepare
    echo $0[production] > echo $0
    [production] < bash
    if [ ! -d ~/webapps/theblizzardtest ]; then mkdir -p ~/webapps/theblizzardtest; fi[production] > if [ ! -d ~/webapps/theblizzardtest ]; then mkdir -p ~/webapps/theblizzardtest; fi
    if [ ! -L ~/webapps/theblizzardtest/current ] && [ -d ~/webapps/theblizzardtest/current ]; then echo true; fi[production] > if [ ! -L ~/webapps/theblizzardtest/current ] && [ -d ~/webapps/theblizzardtest/current ]; then echo true; fi
    cd ~/webapps/theblizzardtest && if [ ! -d .dep ]; then mkdir .dep; fi[production] > cd ~/webapps/theblizzardtest && if [ ! -d .dep ]; then mkdir .dep; fi
    cd ~/webapps/theblizzardtest && if [ ! -d releases ]; then mkdir releases; fi[production] > cd ~/webapps/theblizzardtest && if [ ! -d releases ]; then mkdir releases; fi
    cd ~/webapps/theblizzardtest && if [ ! -d shared ]; then mkdir shared; fi[production] > cd ~/webapps/theblizzardtest && if [ ! -d shared ]; then mkdir shared; fi
    β€’ done on [production]
    βœ” Ok [3s 890ms]
    ➀ Executing task deploy:lock
    if [ -f ~/webapps/theblizzardtest/.dep/deploy.lock ]; then echo 'true'; fi[production] > if [ -f ~/webapps/theblizzardtest/.dep/deploy.lock ]; then echo 'true'; fi
    touch ~/webapps/theblizzardtest/.dep/deploy.lock[production] > touch ~/webapps/theblizzardtest/.dep/deploy.lock
    β€’ done on [production]
    βœ” Ok [1s 188ms]
    ➀ Executing task deploy:release
    if [ -h release ]; then echo 'true'; fi[production] > cd ~/webapps/theblizzardtest && (if [ -h release ]; then echo 'true'; fi)
    [production] < true
    rm -rf "$(readlink release)"[production] > cd ~/webapps/theblizzardtest && (rm -rf "$(readlink release)")
    rm release[production] > cd ~/webapps/theblizzardtest && (rm release)
    [ -d releases ] && [ "$(ls -A releases)" ] && echo "true" || echo "false"[production] > cd ~/webapps/theblizzardtest && ([ -d releases ] && [ "$(ls -A releases)" ] && echo "true" || echo "false")
    [production] < true
    cd releases && ls -t -1 -d */[production] > cd ~/webapps/theblizzardtest && (cd releases && ls -t -1 -d */)
    [production] < 1/
    if [ -f .dep/releases ]; then echo "true"; fi[production] > cd ~/webapps/theblizzardtest && (if [ -f .dep/releases ]; then echo "true"; fi)
    [production] < true
    tail -n 15 .dep/releases[production] > cd ~/webapps/theblizzardtest && (tail -n 15 .dep/releases)
    [production] < 20170413155243,1
    [production] < 20170413155711,1
    [production] < 20170413155902,1
    [production] < 20170413160049,1
    [production] < 20170413160129,2
    [production] < 20170413160422,2
    [production] < 20170413160553,2
    [production] < 20170413160955,2
    [production] < 20170418080346,2
    [production] < 20170418080839,2
    [production] < 20170418082132,2
    [production] < 20170418083340,2
    [production] < 20170418083751,2
    [production] < 20170418083842,2
    [production] < 20170418091436,2
    if [ -d ~/webapps/theblizzardtest/releases/2 ]; then echo 'true'; fi[production] > cd ~/webapps/theblizzardtest && (if [ -d ~/webapps/theblizzardtest/releases/2 ]; then echo 'true'; fi)
    date +"%Y%m%d%H%M%S"[production] > cd ~/webapps/theblizzardtest && (date +"%Y%m%d%H%M%S")
    [production] < 20170418092534
    echo '20170418092534,2' >> .dep/releases[production] > cd ~/webapps/theblizzardtest && (echo '20170418092534,2' >> .dep/releases)
    mkdir ~/webapps/theblizzardtest/releases/2[production] > cd ~/webapps/theblizzardtest && (mkdir ~/webapps/theblizzardtest/releases/2)
    if [[ "$(man ln)" =~ "--relative" ]]; then echo "true"; fi[production] > cd ~/webapps/theblizzardtest && (if [[ "$(man ln)" =~ "--relative" ]]; then echo "true"; fi)
    [production] < true
    ln -nfs --relative ~/webapps/theblizzardtest/releases/2 ~/webapps/theblizzardtest/release[production] > cd ~/webapps/theblizzardtest && (ln -nfs --relative ~/webapps/theblizzardtest/releases/2 ~/webapps/theblizzardtest/release)
    β€’ done on [production]
    βœ” Ok [15s 592ms]
    ➀ Executing task deploy:update_code
    which git[production] > which git
    [production] < /usr/bin/git
    /usr/bin/git version[production] > /usr/bin/git version
    [production] < git version 2.7.4
    if [ -h ~/webapps/theblizzardtest/release ]; then echo 'true'; fi[production] > if [ -h ~/webapps/theblizzardtest/release ]; then echo 'true'; fi
    [production] < true
    readlink ~/webapps/theblizzardtest/release[production] > readlink ~/webapps/theblizzardtest/release
    [production] < releases/2
    /usr/bin/git clone   --recursive -q [email protected]:daykinstorey/blizzard-2017.git ~/webapps/theblizzardtest/releases/2 2>&1[production] > /usr/bin/git clone   --recursive -q [email protected]:daykinstorey/blizzard-2017.git ~/webapps/theblizzardtest/releases/
    2 2>&1
    β€’ done on [production]
    βœ” Ok [8s 63ms]
    ➀ Executing task deploy:shared
    β€’ done on [production]
    βœ” Ok [0ms]
    ➀ Executing task deploy:writable
    β€’ done on [production]
    βœ” Ok [0ms]
    ➀ Executing task deploy:vendors
    if hash composer 2>/dev/null; then echo 'true'; fi[production] > if hash composer 2>/dev/null; then echo 'true'; fi
    [production] < true
    which composer[production] > which composer
    [production] < /usr/sbin/composer
    which php[production] > which php
    ➀ Executing task deploy:failed
    β€’ done on [production]
    βœ” Ok [2ms]
    ➀ Executing task deploy:unlock
    rm -f ~/webapps/theblizzardtest/.dep/deploy.lock[production] > rm -f ~/webapps/theblizzardtest/.dep/deploy.lock
    β€’ done on [production]
    βœ” Ok [501ms]
    
                                                                                                                                
      [RuntimeException]                                                                                                        
      The command "ssh -A -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -p '22' '162.13.127.83' bash -s" failed.  
      Exit Code: 1(General error)                                                                                               
      Output:                                                                                                                   
      ================                                                                                                          
      Error Output:                                                                                                             
      ================                                                                                                          
      Warning: Permanently added '1.13.127.83' (ECDSA) to the list of known hosts.                                            
                                                                                                                                
    
    Exception trace:
     () at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Remote/NativeSsh.php:103
     Deployer\Server\Remote\NativeSsh->run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/functions.php:319
     Deployer\run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/recipe/common.php:85
     Deployer\{closure}() at n/a:n/a
     call_user_func() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:125
     Deployer\Server\Environment->get() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:175
     Deployer\Server\Environment->parseCallback() at n/a:n/a
     preg_replace_callback() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:161
     Deployer\Server\Environment->parse() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:138
     Deployer\Server\Environment->get() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:175
     Deployer\Server\Environment->parseCallback() at n/a:n/a
     preg_replace_callback() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Server/Environment.php:161
     Deployer\Server\Environment->parse() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/functions.php:752
     Deployer\parse() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/functions.php:294
     Deployer\run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/recipe/deploy/vendors.php:12
     Deployer\{closure}() at n/a:n/a
     call_user_func() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Task/Task.php:85
     Deployer\Task\Task->run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Executor/SeriesExecutor.php:40
     Deployer\Executor\SeriesExecutor->run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Console/TaskCommand.php:103
     Deployer\Console\TaskCommand->execute() at /home/vagrant/blizzard-dev/vendor/symfony/console/Command/Command.php:261
     Symfony\Component\Console\Command\Command->run() at /home/vagrant/blizzard-dev/vendor/symfony/console/Application.php:843
     Symfony\Component\Console\Application->doRunCommand() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Console/Application.php:123
     Deployer\Console\Application->doRunCommand() at /home/vagrant/blizzard-dev/vendor/symfony/console/Application.php:189
     Symfony\Component\Console\Application->doRun() at /home/vagrant/blizzard-dev/vendor/symfony/console/Application.php:120
     Symfony\Component\Console\Application->run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/src/Deployer.php:190
     Deployer\Deployer->run() at /home/vagrant/blizzard-dev/vendor/deployer/deployer/bin/dep:120
    
    Reviewed by pmhou at 2017-04-18 09:35
  • 11. Keep releases keeps adding directories (named 1, 1.1, 1.1.2, 1.1.2.3)

    | Q | A | ----------------- | --- | Issue Type | Bug | Deployer Version | 4.2 | Local Machine OS | Ubuntu 16.10 | Remote Machine OS | Ubuntu 16.10

    Description

    the set('keep_releases', 3); command does not appear to work. Deployer keeps adding directories (with names and in this order: '1', '2' , '1.1' , '1.1.2' , '1.1.2.3' ) without deleting any previous release directories. This results in quickly filling up the disk space.

    Apart for this problem, Deploy deploys correctly the new software on the remote web server and does not output any error. Thank you for your help. Best regards, Filippo

    Running deploy

    Steps to reproduce

    dep deploy.php

    Content of deploy.php

    
    namespace Deployer;
    //require_once 'recipe/common.php';
    require 'recipe/laravel.php';
    
    //use function Deployer\{server, task, run, set, get, add, before, after};
    
    set('ssh_type', 'native');
    set('ssh_multiplexing', true);
    
    set('repository', '[email protected]:repository');
    
    // Laravel writable dirs
    add('shared_files', []);
    add('writable_dirs', ['storage', 'vendor']);
    
    server('staging', 'hosting', 22232)
        ->user('usename')
        ->password('pwd')
        ->set('branch', 'master')
        ->set('deploy_path', '/home/provrtsp/public_html/promarket11.com')
        ->pty(true);
    
    set('keep_releases', 3);
    
    //->identityFile('~/.ssh/id_rsa.pub', '~/.ssh/id_rsa')
    
    /**
     * Setup the environment file in the new release
     */
    task('environment', function () {
        run('cp /home/provrtsp/shared/env {{release_path}}/.env');
       
    })->desc('Environment setup');
    
    task('composer_rerun', function () {
        run('cd /home/provrtsp/public_html/promarket11.com/current; php ~/composer.phar install ');
    })->desc('Environment setup');
    
    // Laravel writable dirs
    set('writable_dirs', ['storage', 'vendor']);
    
    // to be added to task call below 'deploy:symlink',
    
    /**
     * Main task
     */
    task('deploy', [
        'deploy:prepare',
        'deploy:release',
        'deploy:update_code',
        'deploy:vendors',
        'deploy:symlink',
        'cleanup',
        'environment',
    ])->desc('Deploy your project');
    
    after('deploy', 'success');
    after('success', 'composer_rerun');                                                                                                           
                                                        
    

    Output log

    With enabled option for verbose output -vvv.

    (this run creates the release directory named 1.1.2.3 )

    $ dep deploy -vvv
    ➀ Executing task deploy:prepare [staging] > echo $0 [staging] < bash [staging] > if [ ! -d /home/provrtsp/public_html/promarket11.com ]; then mkdir -p /home/provrtsp/public_html/promarket11.com; fi [staging] > if [ ! -L /home/provrtsp/public_html/promarket11.com/current ] && [ -d /home/provrtsp/public_html/promarket11.com/current ]; then echo true; fi [staging] > cd /home/provrtsp/public_html/promarket11.com && if [ ! -d .dep ]; then mkdir .dep; fi [staging] > cd /home/provrtsp/public_html/promarket11.com && if [ ! -d releases ]; then mkdir releases; fi [staging] > cd /home/provrtsp/public_html/promarket11.com && if [ ! -d shared ]; then mkdir shared; fi β€’ done on [staging] βœ” Ok [5s 306ms] ➀ Executing task deploy:release [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -h release ]; then echo 'true'; fi) [staging] > cd /home/provrtsp/public_html/promarket11.com && ([ -d releases ] && [ "$(ls -A releases)" ] && echo "true" || echo "false") [staging] < true [staging] > cd /home/provrtsp/public_html/promarket11.com && (cd releases && ls -t -d /) [staging] < 1.1.2/ 1.1/ 2/ 1/ [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -f .dep/releases ]; then echo "true"; fi) [staging] < true [staging] > cd /home/provrtsp/public_html/promarket11.com && (tail -n 11 .dep/releases) [staging] < 20170209064323,1 [staging] < 20170209064710,2 [staging] < 20170209065719,1.1 [staging] < 20170209070156,1.1.2 [staging] < 20170209071015,1.1.2 [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -d /home/provrtsp/public_html/promarket11.com/releases/1 ]; then echo 'true'; fi) [staging] < true [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -d /home/provrtsp/public_html/promarket11.com/releases/1.1 ]; then echo 'true'; fi) [staging] < true [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -d /home/provrtsp/public_html/promarket11.com/releases/1.1.2 ]; then echo 'true'; fi) [staging] < true [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [ -d /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 ]; then echo 'true'; fi) [staging] > cd /home/provrtsp/public_html/promarket11.com && (date +"%Y%m%d%H%M%S") [staging] < 20170209071307 [staging] > cd /home/provrtsp/public_html/promarket11.com && (echo '20170209071307,1.1.2.3' >> .dep/releases) [staging] > cd /home/provrtsp/public_html/promarket11.com && (mkdir /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3) [staging] > cd /home/provrtsp/public_html/promarket11.com && (if [[ "$(man ln)" =~ "--relative" ]]; then echo "true"; fi) [staging] < bash: man: command not found [staging] > cd /home/provrtsp/public_html/promarket11.com && (ln -nfs /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 /home/provrtsp/public_html/promarket11.com/release) β€’ done on [staging] βœ” Ok [8s 97ms] ➀ Executing task deploy:update_code [staging] > which git [staging] < /usr/local/bin/git [staging] > /usr/local/bin/git version [staging] < git version 2.10.0 [staging] > if [ -h /home/provrtsp/public_html/promarket11.com/release ]; then echo 'true'; fi [staging] < true [staging] > readlink /home/provrtsp/public_html/promarket11.com/release [staging] < /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 [staging] > /usr/local/bin/git clone -b master --recursive -q [email protected]:nerifil/mp.git /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 2>&1 β€’ done on [staging] βœ” Ok [17s 415ms] ➀ Executing task deploy:vendors [staging] > if hash composer 2>/dev/null; then echo 'true'; fi [staging] < true [staging] > which composer [staging] < /opt/cpanel/composer/bin/composer [staging] > cd /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 && /opt/cpanel/composer/bin/composer install --verbose --prefer-dist --no-progress --no-interaction --no-dev --optimize-autoloader [staging] < Loading composer repositories with package information [staging] < Installing dependencies from lock file [staging] < Dependency resolution completed in 0.001 seconds [staging] < Analyzed 135 packages to resolve dependencies [staging] < Analyzed 328 rules to resolve dependencies [staging] < - Installing symfony/process (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing knplabs/knp-snappy (0.4.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing vlucas/phpdotenv (v2.4.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/polyfill-mbstring (v1.3.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/var-dumper (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/translation (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/routing (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/http-foundation (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/event-dispatcher (v3.2.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing psr/log (1.0.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/debug (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/http-kernel (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/finder (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/console (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing swiftmailer/swiftmailer (v5.4.5) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing paragonie/random_compat (v2.0.4) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing ramsey/uuid (3.5.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing nikic/php-parser (v3.0.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing jakub-onderka/php-console-color (0.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing jakub-onderka/php-console-highlighter (v0.3.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing dnoegel/php-xdg-base-dir (0.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing psy/psysh (v0.8.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing nesbot/carbon (1.22.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing mtdowling/cron-expression (v1.2.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing monolog/monolog (1.22.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing league/flysystem (1.0.34) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/polyfill-util (v1.3.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/polyfill-php56 (v1.3.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing jeremeamia/superclosure (2.3.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing doctrine/inflector (v1.1.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing classpreloader/classpreloader (3.1.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing laravel/framework (v5.3.30) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing barryvdh/laravel-snappy (v0.3.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/yaml (v3.2.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/dom-crawler (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/css-selector (v3.1.10) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing symfony/browser-kit (v3.2.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/diff (1.4.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/recursion-context (2.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/exporter (2.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/comparator (1.2.4) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/version (2.0.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/resource-operations (1.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/object-enumerator (2.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/global-state (1.1.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/environment (2.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/php-text-template (1.2.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing doctrine/instantiator (1.0.5) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/phpunit-mock-objects (3.4.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/php-timer (1.0.8) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/php-file-iterator (1.4.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing sebastian/code-unit-reverse-lookup (1.0.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/php-token-stream (1.4.9) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/php-code-coverage (4.0.5) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing webmozart/assert (1.2.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpdocumentor/reflection-common (1.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpdocumentor/type-resolver (0.2.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpdocumentor/reflection-docblock (3.1.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpspec/prophecy (v1.6.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing myclabs/deep-copy (1.6.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing phpunit/phpunit (5.7.12) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing psr/http-message (1.0.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing guzzlehttp/psr7 (1.3.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing guzzlehttp/promises (v1.3.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing guzzlehttp/guzzle (6.2.2) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing facebook/webdriver (1.3.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing behat/gherkin (v4.4.5) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing codeception/codeception (2.2.9) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing h4cc/wkhtmltoimage-amd64 (0.12.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing h4cc/wkhtmltopdf-amd64 (0.12.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing laravelcollective/html (v5.3.1) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing pusher/pusher-php-server (2.6.3) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < - Installing stripe/stripe-php (v4.4.0) [staging] < Loading from cache [staging] < Extracting archive [staging] < [staging] < Generating optimized autoload files [staging] < Warning: Ambiguous class resolution, "App\Exceptions\Handler" was found in both "/home/provrtsp/public_html/promarket11.com/releases/1.1.2.3/app/Exceptions/HandlerNO.php" and "/home/provrtsp/public_html/promarket11.com/releases/1.1.2.3/app/Exceptions/Handler.php", the first will be used. [staging] < > post-install-cmd: Illuminate\Foundation\ComposerScripts::postInstall [staging] < > post-install-cmd: php artisan optimize [staging] < Generating optimized class loader [staging] < Compiling common classes β€’ done on [staging] βœ” Ok [110s 895ms] ➀ Executing task deploy:symlink [staging] > if [[ "$(man mv)" =~ "--no-target-directory" ]]; then echo "true"; fi [staging] < bash: man: command not found [staging] > cd /home/provrtsp/public_html/promarket11.com && ln -nfs /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3 current [staging] > cd /home/provrtsp/public_html/promarket11.com && rm release β€’ done on [staging] βœ” Ok [1s 637ms] ➀ Executing task cleanup [staging] > cd /home/provrtsp/public_html/promarket11.com && if [ -e release ]; then rm release; fi [staging] > cd /home/provrtsp/public_html/promarket11.com && if [ -h release ]; then rm release; fi β€’ done on [staging] βœ” Ok [919ms] ➀ Executing task environment [staging] > cp /home/provrtsp/shared/env /home/provrtsp/public_html/promarket11.com/releases/1.1.2.3/.env β€’ done on [staging] βœ” Ok [5s 43ms] ➀ Executing task success βœ” Ok [0ms] ➀ Executing task composer_rerun [staging] > cd /home/provrtsp/public_html/promarket11.com/current; php ~/composer.phar install [staging] < Loading composer repositories with package information [staging] < Installing dependencies (including require-dev) from lock file [staging] < - Installing pimple/pimple (v3.0.2) [staging] < Loading from cache [staging] < [staging] < - Installing phpseclib/phpseclib (2.0.4) [staging] < Loading from cache [staging] < [staging] < - Installing psr/cache (1.0.1) [staging] < Loading from cache [staging] < [staging] < - Installing symfony/cache (v3.2.3) [staging] < Loading from cache [staging] < [staging] < - Installing symfony/expression-language (v3.2.3) [staging] < Loading from cache [staging] < [staging] < - Installing evenement/evenement (v2.0.0) [staging] < Loading from cache [staging] < [staging] < - Installing react/stream (v0.4.6) [staging] < Loading from cache [staging] < [staging] < - Installing react/promise (v2.5.0) [staging] < Loading from cache [staging] < [staging] < - Installing react/event-loop (v0.4.2) [staging] < Loading from cache [staging] < [staging] < - Installing react/socket (v0.4.6) [staging] < Loading from cache [staging] < [staging] < - Installing react/cache (v0.4.1) [staging] < Loading from cache [staging] < [staging] < - Installing react/dns (v0.4.3) [staging] < Loading from cache [staging] < [staging] < - Installing react/socket-client (v0.4.6) [staging] < Loading from cache [staging] < [staging] < - Installing react/http-client (v0.4.15) [staging] < Loading from cache [staging] < [staging] < - Installing react/http (v0.4.2) [staging] < Loading from cache [staging] < [staging] < - Installing react/child-process (v0.4.1) [staging] < Loading from cache [staging] < [staging] < - Installing react/react (v0.4.2) [staging] < Loading from cache [staging] < [staging] < - Installing elfet/pure (v2.0.0) [staging] < Loading from cache [staging] < [staging] < - Installing deployer/deployer (v4.2.1) [staging] < Loading from cache [staging] < [staging] < - Installing deployer/phar-update (v2.0.0) [staging] < Loading from cache [staging] < [staging] < - Installing fzaninotto/faker (v1.6.0) [staging] < Loading from cache [staging] < [staging] < - Installing hamcrest/hamcrest-php (v1.2.2) [staging] < Loading from cache [staging] < [staging] < - Installing mockery/mockery (0.9.7) [staging] < Loading from cache [staging] < [staging] < phpseclib/phpseclib suggests installing ext-libsodium (SSH2/SFTP can make use of some algorithms provided by the libsodium-php extension.) [staging] < symfony/cache suggests installing symfony/polyfill-apcu (For using ApcuAdapter on HHVM) [staging] < react/event-loop suggests installing ext-event (~1.0) [staging] < react/event-loop suggests installing ext-libev () [staging] < react/event-loop suggests installing ext-libevent (>=0.1.0) [staging] < react/react suggests installing ext-event (Allows for use of a more performant event-loop implementation.) [staging] < react/react suggests installing ext-libev (Allows for use of a more performant event-loop implementation.) [staging] < react/react suggests installing ext-libevent (Allows for use of a more performant event-loop implementation.) [staging] < Generating autoload files [staging] < > Illuminate\Foundation\ComposerScripts::postInstall [staging] < > php artisan optimize [staging] < Generating optimized class loader [staging] < Compiling common classes β€’ done on [staging] βœ” Ok [18s 103ms] Successfully deployed!

    Reviewed by filipponeri at 2017-02-09 12:19
  • 12. Allow setting of composer variables

    • [ ] Bug fix #…?
    • [x] New feature?
    • [ ] BC breaks?
    • [ ] Tests added?
    • [x] Docs added?

    We deploy different composer.json file based on the environment we want to deploy on, this change will allow the user to set the composer.json based on the host. The default is '' which will just use the default composer.json. Sample usage:

    host('test')
        ->set('composer_env_vars', 'COMPOSER=composer-test.json')
        ->set('deploy_path', '/var/www/html);
    
    host('dev')
        ->set('composer_env_vars', 'COMPOSER=composer-dev.json')
        ->set('deploy_path', '/var/www/html);
    
    Reviewed by dcanaud at 2022-08-14 06:52
  • 13. ci/release: Do not omit the autoload section from composer.json

    Ever since https://github.com/deployphp/deployer/pull/3051, many keys in the composer.json file are omitted when releasing a new Deployer version in order to have no version constraints for the package. This is all fine when just using deployer as-is, but becomes problematic when building on top of Deployer and depend on the namespaces and classes to be available.

    With this change, external applications can make use of the internal Deployer classes, while the requirements are not being propagated through Composer.

    Reviewed by tdgroot at 2022-08-08 10:24
  • 14. Links still to deployer.phar instead of dep

    The changelog of https://github.com/deployphp/deployer/releases/tag/v7.0.0-rc.9 says:

    Phar renamed back to depfrom deployer.phar + source code also available now.

    However, assets since rc.9 and download-page still link use deployer.phar:

    • https://github.com/deployphp/deployer/releases/tag/v7.0.0
    • https://github.com/deployphp/deployer/releases/tag/v7.0.0-rc.9
    • https://deployer.org/download
    Reviewed by alexgit2k at 2022-08-06 19:05
  • 15. Deployer hang on success or fail on gitlab runner shell

    • Deployer version: 7
    • Deployment OS: Centos 7 - Plesk
    • Gitlab 15.2

    It seems that it does not return status exit.

    deploy.php

    require 'recipe/cakephp.php';

    set('ssh_multiplexing', true);

    set('bin/composer', function () { return '{{bin/php}} /usr/lib64/plesk-9.0/composer.phar'; });

    $config = []; $configFile = dirname(dirname(FILE)) . '/.deploy.ini'; if (file_exists($configFile)) { $config = parse_ini_file($configFile); }

    $getConfig = function (string $key) use ($config): ?string { if ($envValue = getenv($key)) { return $envValue; }

    return $config[$key] ?? null;
    

    }; $projectName = $getConfig('DEPLOY_PROJECT_NAME') ?? 'project';

    set('repository', '[email protected]:programadorwebfreelance/{$projectName}.git');

    host('master') ->setHostname( '$projectName.master.xxxx.com") ->setIdentityFile('~/.ssh/id_rsa') ->setRemoteUser($getConfig('SERVER_USER')) ->setSshArguments(['-o UserKnownHostsFile=/dev/null']) ->set('branch', 'master') ->set('composer_options', '--verbose --prefer-dist --optimize-autoloader --no-progress --no-interaction') ->set('deploy_path', '/var/www/vhosts/xxx.xcom'.$projectName.'/master');

    set('shared_dirs', [ 'logs', 'files', ]);

    set('shared_files', [ 'config/app_local.php', 'config/asset_compress.local.ini', ]);

    task('deploy:run_migrations', function () { run('{{bin/php}} {{release_path}}/bin/cake.php migrations migrate --no-lock'); run('{{bin/php}} {{release_path}}/bin/cake.php schema_cache build'); })->desc('Run migrations, clear all caches');

    Captura de Pantalla 2022-08-06 a las 18 44 18
    Reviewed by programadorwebfreelance at 2022-08-06 16:47
  • 16. Add default_selector and improve documentation on host labels and selection

    • [ ] Bug fix #…?
    • [x] New feature #3198
    • [ ] BC breaks?
    • [ ] Tests added?
    • [x] Docs added?

    The default_selector was pretty quick to implement. I also added some documentation.

    Would like to get some feedback on this!

    congrats on the v7 release πŸ”₯

    Reviewed by marvinhinz at 2022-08-03 23:55
Deployer based deployment for WordPress with media and database synchronisation.

deployer-extended-wordpress What does it do? Should I use "deployer-extended-wordpress" or "deployer-extended-wordpress-composer"? Dependencies Instal

Jun 3, 2021
PHing Is Not GNU make; it's a PHP project build system or build tool based on Apache Ant.

P H I N G Thank you for using PHING! PHing Is Not GNU make; it's a PHP project build system or build tool based on Apache Ant. You can do anything wit

Aug 4, 2022
Deploy your PHP with PHP. Inspired by Capistrano and Vlad.

Pomander A light-weight flexible deployment tool for deploying web applications. This project was inspired by Capistrano and Vlad the Deployer, as wel

Jun 4, 2022
PHP transpiler - Write and deploy modern PHP 8 code, today.

Phabel Write and deploy modern PHP 8 code, today. This is a transpiler that allows native usage of PHP 8+ features and especially syntax in projects a

Aug 9, 2022
Elegant SSH tasks for PHP.

Laravel Envoy Introduction Laravel Envoy provides a clean, minimal syntax for defining common tasks you run on your remote servers. Using Blade style

Aug 9, 2022
A deployer library for PHP 5.3

Plum An object oriented deployer library Installation and configuration Plum does not provide and autoloader but follow the PSR-0 convention. $plum =

Feb 5, 2022
πŸš€ Zero-downtime deployment out-of-the-box

?? Laravel Deployer Looking for the old Laravel Deployer? Click here. Laravel Deployer is no longer the package it used to be. Since that package was

Aug 12, 2022
YCOM Impersonate. Login as selected YCOM user πŸ§™β€β™‚οΈin frontend.

YCOM Impersonate Login as selected YCOM user in frontend. Features: Backend users with admin rights or YCOM[] rights, can be automatically logged in v

Jan 19, 2022
TeleBot - Easy way to create Telegram-bots in PHP. Rich Laravel support out of the box.

TeleBot is a PHP library for telegram bots development. Rich Laravel support out of the box. Has an easy, clean, and extendable way to handle telegram Updates.

Aug 8, 2022
A Laravel dashboard front-end scaffolding preset for Tailwind CSS - Support RTL out of the box.
A Laravel dashboard front-end scaffolding preset for Tailwind CSS - Support RTL out of the box.

?? Laravel tailwind css dashboard preset A Laravel dashboard front-end scaffolding preset for Tailwind CSS - Support RTL out of the box. Usage Fresh i

Aug 5, 2022
Hi Im L, I found a box that I believe it's contain Kira's real ID. for open that box we need to find three keys. let's start looking for them
Hi Im L, I found a box that I believe it's contain Kira's real ID. for open that box we need to find three keys. let's start looking for them

DeathNote ctf Description are you smart enaugh to help me capturing the three keys for open the box that contain the real ID of kira? Let's start solv

Apr 19, 2022
Scotch Box is a preconfigured Vagrant Box with a full array of LAMP Stack features to get you up and running with Vagrant in no time.
Scotch Box is a preconfigured Vagrant Box with a full array of LAMP Stack features to get you up and running with Vagrant in no time.

Scotch Box is a preconfigured Vagrant Box with a full array of LAMP Stack features to get you up and running with Vagrant in no time.

Jul 29, 2022
Pux is a fast PHP Router and includes out-of-box controller tools

Pux Pux is a faster PHP router, it also includes out-of-box controller helpers. 2.0.x Branch Build Status (This branch is under development) Benchmark

Jul 27, 2022
πŸ€– Telegram Bot API PHP SDK. Lets you build Telegram Bots easily! Supports Laravel out of the box.
πŸ€– Telegram Bot API PHP SDK. Lets you build Telegram Bots easily! Supports Laravel out of the box.

Telegram Bot API - PHP SDK Telegram Bot PHP SDK lets you develop Telegram Bots in PHP easily! Supports Laravel out of the box. Telegram Bot API is an

Aug 12, 2022
BookStack is an opinionated wiki system that provides a pleasant and simple out of the box experience.

BookStack is an opinionated wiki system that provides a pleasant and simple out of the box experience. New users to an instance should find the experience intuitive and only basic word-processing skills should be required to get involved in creating content on BookStack. The platform should provide advanced power features to those that desire it but they should not interfere with the core simple user experience.

Aug 10, 2022
πŸ––Repository Pattern in Laravel. The package allows to filter by request out-of-the-box, as well as to integrate customized criteria and any kind of filters.
πŸ––Repository Pattern in Laravel. The package allows to filter by request out-of-the-box, as well as to integrate customized criteria and any kind of filters.

Repository Repository Pattern in Laravel. The package allows to filter by request out-of-the-box, as well as to integrate customized criteria and any

Jul 22, 2022
A nice GUI for Laravel Artisan, ready out of the box, configurable and handy for non-CLI experienced developers.

Artisan UI A nice GUI for Laravel Artisan, ready out of the box, configurable and handy for non-CLI experienced developers. Supported commands must be

Dec 3, 2021
LaravelS is an out-of-the-box adapter between Swoole and Laravel/Lumen.
LaravelS is an out-of-the-box adapter between Swoole and Laravel/Lumen.

?? LaravelS is an out-of-the-box adapter between Swoole and Laravel/Lumen.

Aug 11, 2022
Automatically load the next page of products in Magento. Easy to install and configure, this module works 100% out of the box with vanilla Magento 1.9.x and earlier.

Automatically load the next page of products in Magento. Easy to install and configure, this module works 100% out of the box with vanilla Magento 1.9.x and earlier.

Nov 20, 2021
Two-Factor Authentication for all your users out-of-the-box.

Two Factor On-premises Two-Factor Authentication for all your users out of the box. use Illuminate\Support\Facades\Auth; use Laragear\TwoFactor\TwoFac

Aug 7, 2022