diff --git a/application/clicommands/ImportsourceCommand.php b/application/clicommands/ImportsourceCommand.php index 477fdf59..6bee37d0 100644 --- a/application/clicommands/ImportsourceCommand.php +++ b/application/clicommands/ImportsourceCommand.php @@ -67,6 +67,23 @@ class ImportsourceCommand extends Command $this->showImportStateDetails($source); } + /** + * This command deletes the given Import Source. + * + * USAGE + * + * icingacli director importsource delete --id + * + * OPTIONS + * + * --id An Import Source ID. Use the list command to figure out + */ + public function deleteAction() + { + $source = $this->getImportSource(); + $source->delete(); + } + /** * Fetch current data from a given Import Source *