mirror of
https://github.com/tiennm99/coolify.git
synced 2026-08-20 04:23:34 +00:00
Use the current request scheme/host when no FQDN or public IP is set, skipping loopback hosts. Polish boarding/server create cards, optional listbox tooltips, and cover the layout and Sentinel URL behavior in tests.
18 lines
909 B
PHP
18 lines
909 B
PHP
<?php
|
|
|
|
test('sentinel startup regenerates an empty endpoint from instance settings', function () {
|
|
$action = file_get_contents(dirname(__DIR__, 2).'/app/Actions/Server/StartSentinel.php');
|
|
$component = file_get_contents(dirname(__DIR__, 2).'/app/Livewire/Server/Sentinel.php');
|
|
|
|
expect($action)
|
|
->toContain('ensureSentinelUrl()')
|
|
->and($component)
|
|
->toContain('$this->sentinelCustomUrl = $this->server->settings->sentinel_custom_url;')
|
|
->and(file_get_contents(dirname(__DIR__, 2).'/app/Models/ServerSetting.php'))
|
|
->toContain('generateSentinelUrl(ignoreEvent: true)')
|
|
->toContain('sentinelUrlFromCurrentRequest()')
|
|
->toContain('Set an instance FQDN, public IP, or reachable Coolify URL before enabling Sentinel.')
|
|
->and($component)
|
|
->toContain('$this->sentinelCustomUrl = $this->server->settings->sentinel_custom_url;');
|
|
});
|