mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Add nameservers variable
This commit is contained in:
@@ -62,7 +62,8 @@ App::get('/v1/console/variables')
|
||||
'_APP_DOMAIN_ENABLED' => $isDomainEnabled,
|
||||
'_APP_ASSISTANT_ENABLED' => $isAssistantEnabled,
|
||||
'_APP_DOMAIN_SITES' => System::getEnv('_APP_DOMAIN_SITES'),
|
||||
'_APP_OPTIONS_FORCE_HTTPS' => System::getEnv('_APP_OPTIONS_FORCE_HTTPS')
|
||||
'_APP_OPTIONS_FORCE_HTTPS' => System::getEnv('_APP_OPTIONS_FORCE_HTTPS'),
|
||||
'_APP_DOMAINS_NAMESERVERS' => System::getEnv('_APP_DOMAINS_NAMESERVERS'),
|
||||
]);
|
||||
|
||||
$response->dynamic($variables, Response::MODEL_CONSOLE_VARIABLES);
|
||||
|
||||
@@ -66,6 +66,15 @@ class ConsoleVariables extends Model
|
||||
'default' => '',
|
||||
'example' => 'enabled',
|
||||
]
|
||||
)
|
||||
->addRule(
|
||||
'_APP_DOMAINS_NAMESERVERS',
|
||||
[
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Comma-separated list of nameservers.',
|
||||
'default' => '',
|
||||
'example' => 'ns1.example.com,ns2.example.com',
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -34,5 +34,6 @@ class ConsoleConsoleClientTest extends Scope
|
||||
$this->assertIsBool($response['body']['_APP_ASSISTANT_ENABLED']);
|
||||
$this->assertIsString($response['body']['_APP_DOMAIN_SITES']);
|
||||
$this->assertIsString($response['body']['_APP_OPTIONS_FORCE_HTTPS']);
|
||||
$this->assertIsString($response['body']['_APP_DOMAINS_NAMESERVERS']);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,8 @@ use Tests\E2E\Client;
|
||||
trait ProxyBase
|
||||
{
|
||||
use Async;
|
||||
|
||||
// TODO: @Meldiron different kinds of rules, creation failure, list, get, update status
|
||||
|
||||
protected function createRule(mixed $params): mixed
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user