kevinsimard/laravel-deploy

Deploy Laravel application through SSH

v1.0.4 2016-09-22 14:17 UTC

This package is not auto-updated.

Last update: 2024-11-09 18:59:18 UTC


README

Installation

Add Kevinsimard\Deploy\Command\Task\DeployTask to the list of commands in app/Console/Kernel.php.

<?php namespace App\Console;

use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;

class Kernel extends ConsoleKernel {

    /**
     * @var array
     */
    protected $commands = [
        ...
        "Kevinsimard\Deploy\Command\Task\DeployTask",
    ];
...

Add/edit the config/remote.php file.

<?php

return [
    // default connection name
    "default" => "local",

    // connections
    "connections" => [
        "local" => [
            "host"      => "127.0.0.1",
            "username"  => "username",
            "password"  => "password",
            "key"       => "",
            "keytext"   => "",
            "keyphrase" => "",
            "agent"     => "",
        ],
    ],

    // connection groups
    "groups" => [
        "web" => ["local"]
    ],
];

Artisan Command

php artisan deploy:app <ROOT>

The following options are available:

  • --remote=<CONNECTION>: Remote connection/group name
  • --no-composer: Do not install dependencies
  • --no-migration: Do not run migration files
  • --no-maintenance: Do not use maintenance mode

Code Structure

├── src
│   └── Kevinsimard
│       └── Deploy
│           └── Command
│               └── Task
│                   └── DeployTask.php
├── .editorconfig
├── .gitattributes
├── .gitignore
├── LICENSE.md
├── README.md
└── composer.json

License

This package is open-sourced software licensed under the MIT license.