跳转至

common

Source

Configuration

user

Source

Name of current user who is running deploy. It will be shown in dep status command as author. If not set will try automatically get git user name, otherwise output of whoami command.

keep_releases

Source

Number of releases to preserve in releases folder.

```php title="Default value" 5



### repository
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L51)

Repository to deploy.



### shared_dirs
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L58)

List of dirs what will be shared between releases.
Each release will have symlink to those dirs stored in {{deploy_path}}/shared dir.
```php
set('shared_dirs', ['storage']);

shared_files

Source

List of files what will be shared between releases. Each release will have symlink to those files stored in {{deploy_path}}/shared dir.

set('shared_files', ['.env']);

copy_dirs

Source

List of dirs to copy between releases. For example you can copy node_modules to speedup npm install.

clear_paths

Source

List of paths to remove from release_path.

clear_use_sudo

Source

Use sudo for deploy:clear_path task?

```php title="Default value" false



### use_relative_symlink
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L77)





### use_atomic_symlink
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L80)





### default_timeout
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L87)

Default timeout for `run()` and `runLocally()` functions.

Set to `null` to disable timeout.

```php title="Default value"
300

env

Source

Remote environment variables.

set('env', [
    'KEY' => 'something',
]);

It is possible to override it per run() call.

run('echo $KEY', ['env' => ['KEY' => 'over']]

dotenv

Source

Path to .env file which will be used as environment variables for each command per run().

set('dotenv', '{{current_path}}/.env');

```php title="Default value" false



### current_path
[Source](https://github.com/deployphp/deployer/blob/master/recipe/common.php#L120)

Return current release path. Default to {{deploy_path}}/`current`.
```php
set('current_path', '/var/public_html');

php title="Default value" '{{deploy_path}}/current'

sudo_askpass

Source

Path to a file which will store temp script with sudo password. Defaults to .dep/sudo_pass. This script is only temporary and will be deleted after sudo command executed.

Tasks

deploy:prepare

Source

.

This task is group task which contains next tasks: * deploy:info * deploy:setup * deploy:lock * deploy:release * deploy:update_code * deploy:shared * deploy:writable

deploy:publish

Source

.

This task is group task which contains next tasks: * deploy:symlink * deploy:unlock * deploy:cleanup * deploy:success

deploy:success

Source

.

Prints success message

deploy:failed

Source

.

Hook on deploy failure.

logs

Source

Follow latest application logs.

Follow latest application logs.

Back to top