PHP Класс REBELinBLUE\Deployer\Console\Commands\InstallApp

TODO: Refactor the validator to reduce duplication TODO: Move the writing the env file to another class.
Наследование: extends Illuminate\Console\Command, use trait REBELinBLUE\Deployer\Console\Commands\Traits\AskAndValidate
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$description string The console command description.
$signature string The name and signature of the console command.

Открытые методы

Метод Описание
__construct ( REBELinBLUE\Deployer\Contracts\Repositories\UserRepositoryInterface $repository = null ) InstallApp constructor.
handle ( ) : mixed Execute the console command.

Защищенные методы

Метод Описание
block ( string | array $messages, string $type = 'error' ) A wrapper around symfony's formatter helper to output a block.
checkRequirements ( ) : boolean Checks the system meets all the requirements needed to run Deployer.
clearCaches ( ) Clears all Laravel caches.
generateJWTKey ( ) : string Generates a key for JWT.
header ( string $header ) Outputs a header block.
migrate ( boolean $seed = false ) Calls the artisan migrate to set up the database in development mode it also seeds the DB.
optimize ( ) Runs the artisan optimize commands.
writeEnvFile ( array $input ) : boolean Writes the configuration data to the config file.

Приватные методы

Метод Описание
generateKey ( ) Calls the artisan key:generate to set the APP_KEY.
getAdminInformation ( ) : array Prompts for the admin user details.
getDatabaseDrivers ( ) : array Gets an array of available PDO drivers which are supported by Laravel.
getDatabaseInformation ( ) : array Prompts the user for the database connection details.
getEmailInformation ( ) : array Prompts the user for the details for the email setup.
getInstallInformation ( ) : array Prompts the user for the basic setup information.
getLocales ( ) : array Gets a list of the available locales.
getTimezoneLocations ( integer $region ) : array Gets a list of available locations in the supplied region.
getTimezoneRegions ( ) : array Gets a list of timezone regions.
verifyDatabaseDetails ( array $database ) : boolean Verifies that the database connection details are correct.
verifyNotInstalled ( ) : boolean Ensures that Deployer has not been installed yet.

Описание методов

__construct() публичный Метод

InstallApp constructor.
public __construct ( REBELinBLUE\Deployer\Contracts\Repositories\UserRepositoryInterface $repository = null )
$repository REBELinBLUE\Deployer\Contracts\Repositories\UserRepositoryInterface

block() защищенный Метод

A wrapper around symfony's formatter helper to output a block.
protected block ( string | array $messages, string $type = 'error' )
$messages string | array Messages to output
$type string The type of message to output

checkRequirements() защищенный Метод

Checks the system meets all the requirements needed to run Deployer.
protected checkRequirements ( ) : boolean
Результат boolean

clearCaches() защищенный Метод

Clears all Laravel caches.
protected clearCaches ( )

generateJWTKey() защищенный Метод

Generates a key for JWT.
protected generateJWTKey ( ) : string
Результат string

handle() публичный Метод

Execute the console command.
public handle ( ) : mixed
Результат mixed

header() защищенный Метод

Outputs a header block.
protected header ( string $header )
$header string The text to output

migrate() защищенный Метод

Calls the artisan migrate to set up the database in development mode it also seeds the DB.
protected migrate ( boolean $seed = false )
$seed boolean Whether or not to seed the database

optimize() защищенный Метод

Runs the artisan optimize commands.
protected optimize ( )

writeEnvFile() защищенный Метод

Writes the configuration data to the config file.
protected writeEnvFile ( array $input ) : boolean
$input array The config data to write
Результат boolean

Описание свойств

$description защищенное свойство

The console command description.
protected string $description
Результат string

$signature защищенное свойство

The name and signature of the console command.
protected string $signature
Результат string