41 lines
669 B
PHP
41 lines
669 B
PHP
|
<?php
|
||
|
|
||
|
namespace App\Console\Commands;
|
||
|
|
||
|
use App\Jobs\Updater\IUpdater;
|
||
|
use Illuminate\Console\Command;
|
||
|
|
||
|
class SyncDomain extends Command
|
||
|
{
|
||
|
|
||
|
/**
|
||
|
* The console command name.
|
||
|
*
|
||
|
* @var string
|
||
|
*/
|
||
|
protected $signature = "domain:sync";
|
||
|
|
||
|
/**
|
||
|
* The console command description.
|
||
|
*
|
||
|
* @var string
|
||
|
*/
|
||
|
protected $description = "Test Sync a Domain";
|
||
|
|
||
|
/**
|
||
|
* Execute the console command.
|
||
|
*
|
||
|
*/
|
||
|
public function handle()
|
||
|
{
|
||
|
$domain = $this->ask("Domainname");
|
||
|
$ip = $this->ask("New IP");
|
||
|
|
||
|
$job = app(IUpdater::class);
|
||
|
$job->config($domain, $ip);
|
||
|
dispatch($job);
|
||
|
|
||
|
|
||
|
}
|
||
|
}
|