fix: minio / logto url generation
This commit is contained in:
parent
e00c692e33
commit
9a93309bd2
1 changed files with 6 additions and 10 deletions
|
|
@ -225,15 +225,13 @@ function generateServiceSpecificFqdns(ServiceApplication|Application $resource)
|
|||
case $type?->contains('minio'):
|
||||
$MINIO_BROWSER_REDIRECT_URL = $variables->where('key', 'MINIO_BROWSER_REDIRECT_URL')->first();
|
||||
$MINIO_SERVER_URL = $variables->where('key', 'MINIO_SERVER_URL')->first();
|
||||
if (is_null($MINIO_BROWSER_REDIRECT_URL) || is_null($MINIO_SERVER_URL)) {
|
||||
return $payload;
|
||||
}
|
||||
if (is_null($MINIO_BROWSER_REDIRECT_URL?->value)) {
|
||||
|
||||
if (str($MINIO_BROWSER_REDIRECT_URL->value)->isEmpty()) {
|
||||
$MINIO_BROWSER_REDIRECT_URL?->update([
|
||||
'value' => generateFqdn($server, 'console-'.$uuid, true),
|
||||
]);
|
||||
}
|
||||
if (is_null($MINIO_SERVER_URL?->value)) {
|
||||
if (str($MINIO_SERVER_URL->value)->isEmpty()) {
|
||||
$MINIO_SERVER_URL?->update([
|
||||
'value' => generateFqdn($server, 'minio-'.$uuid, true),
|
||||
]);
|
||||
|
|
@ -246,15 +244,13 @@ function generateServiceSpecificFqdns(ServiceApplication|Application $resource)
|
|||
case $type?->contains('logto'):
|
||||
$LOGTO_ENDPOINT = $variables->where('key', 'LOGTO_ENDPOINT')->first();
|
||||
$LOGTO_ADMIN_ENDPOINT = $variables->where('key', 'LOGTO_ADMIN_ENDPOINT')->first();
|
||||
if (is_null($LOGTO_ENDPOINT) || is_null($LOGTO_ADMIN_ENDPOINT)) {
|
||||
return $payload;
|
||||
}
|
||||
if (is_null($LOGTO_ENDPOINT?->value)) {
|
||||
|
||||
if (str($LOGTO_ENDPOINT?->value)->isEmpty()) {
|
||||
$LOGTO_ENDPOINT?->update([
|
||||
'value' => generateFqdn($server, 'logto-'.$uuid),
|
||||
]);
|
||||
}
|
||||
if (is_null($LOGTO_ADMIN_ENDPOINT?->value)) {
|
||||
if (str($LOGTO_ADMIN_ENDPOINT?->value)->isEmpty()) {
|
||||
$LOGTO_ADMIN_ENDPOINT?->update([
|
||||
'value' => generateFqdn($server, 'logto-admin-'.$uuid),
|
||||
]);
|
||||
|
|
|
|||
Loading…
Reference in a new issue