added check:bootstrap

This commit is contained in:
tracer 2024-05-03 19:41:18 +02:00
parent 17e70f14a2
commit b147cda096
3 changed files with 16 additions and 3 deletions

2
TODO
View File

@ -1,9 +1,9 @@
check:cache
check:bootstrap
check:version remove option update, we have -v as option
move stuff to dev:xxx which is not needed for endusers
make use of environment, somehow, dev, prod, test
check log file location
check:config *validate if all required fields are set, sanity checks.
API Endpoint cleanup
check keytype of panel/bindApi
check:configkey => update config.json

View File

@ -2,7 +2,7 @@
"name": "tracer/bindapi",
"description": "manage Bind9 client zones for KeyHelp",
"version": "1.0.9",
"build_number": "376",
"build_number": "377",
"authors": [
{
"name": "Micha Espey",

View File

@ -239,6 +239,12 @@ class CLIController
$this->checkNameservers();
},
description: 'Check version on nameservers'))
->addCommand(command: new Command(
name: 'bootstrap',
callback: function () {
$this->checkBootstrap();
},
description: 'Check version on nameservers'))
->addCommand(command: new Command(
name: 'domains',
callback: function () {
@ -1673,7 +1679,6 @@ class CLIController
}
}
// FIXME add method create bootstrap php, add it to create, delete and update nameservers
public function createOpenAPIBootstrap(): void
{
@ -2429,4 +2434,12 @@ const VERSION = '{$versionSting}';
echo Color::RED . 'Errror: ' . Colors::DEFAULT . 'Missing function opcache_clear()' . PHP_EOL;
}
}
private function checkBootstrap()
{
$this->createOpenAPIBootstrap();
if (!$this->quiet) {
echo 'Created new bootsrap.php' . PHP_EOL;
}
}
}