feat: custom dns servers
This commit is contained in:
@@ -141,8 +141,8 @@
|
||||
if (
|
||||
application.gitSourceId &&
|
||||
application.destinationDockerId &&
|
||||
application.fqdn &&
|
||||
!application.settings.isBot
|
||||
(application.fqdn ||
|
||||
application.settings.isBot)
|
||||
) {
|
||||
await getStatus();
|
||||
statusInterval = setInterval(async () => {
|
||||
@@ -409,37 +409,39 @@
|
||||
</svg>
|
||||
</button></a
|
||||
>
|
||||
<a
|
||||
href={!$disabledButton ? `/applications/${id}/previews` : null}
|
||||
sveltekit:prefetch
|
||||
class="hover:text-orange-500 rounded"
|
||||
class:text-orange-500={$page.url.pathname === `/applications/${id}/previews`}
|
||||
class:bg-coolgray-500={$page.url.pathname === `/applications/${id}/previews`}
|
||||
>
|
||||
<button
|
||||
disabled={$disabledButton}
|
||||
class="icons bg-transparent tooltip tooltip-primary tooltip-bottom text-sm"
|
||||
data-tip="Previews"
|
||||
{#if !application.settings.isBot}
|
||||
<a
|
||||
href={!$disabledButton ? `/applications/${id}/previews` : null}
|
||||
sveltekit:prefetch
|
||||
class="hover:text-orange-500 rounded"
|
||||
class:text-orange-500={$page.url.pathname === `/applications/${id}/previews`}
|
||||
class:bg-coolgray-500={$page.url.pathname === `/applications/${id}/previews`}
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="w-6 h-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
<button
|
||||
disabled={$disabledButton}
|
||||
class="icons bg-transparent tooltip tooltip-primary tooltip-bottom text-sm"
|
||||
data-tip="Previews"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<circle cx="7" cy="18" r="2" />
|
||||
<circle cx="7" cy="6" r="2" />
|
||||
<circle cx="17" cy="12" r="2" />
|
||||
<line x1="7" y1="8" x2="7" y2="16" />
|
||||
<path d="M7 8a4 4 0 0 0 4 4h4" />
|
||||
</svg></button
|
||||
></a
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="w-6 h-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<circle cx="7" cy="18" r="2" />
|
||||
<circle cx="7" cy="6" r="2" />
|
||||
<circle cx="17" cy="12" r="2" />
|
||||
<line x1="7" y1="8" x2="7" y2="16" />
|
||||
<path d="M7 8a4 4 0 0 0 4 4h4" />
|
||||
</svg></button
|
||||
></a
|
||||
>
|
||||
{/if}
|
||||
<div class="border border-coolgray-500 h-8" />
|
||||
<a
|
||||
href={!$disabledButton && $status.application.isRunning ? `/applications/${id}/logs` : null}
|
||||
|
||||
@@ -779,15 +779,17 @@
|
||||
description={$t('application.enable_auto_deploy_webhooks')}
|
||||
/>
|
||||
</div>
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<Setting
|
||||
isCenter={false}
|
||||
bind:setting={previews}
|
||||
on:click={() => changeSettings('previews')}
|
||||
title={$t('application.enable_mr_pr_previews')}
|
||||
description={$t('application.enable_preview_deploy_mr_pr_requests')}
|
||||
/>
|
||||
</div>
|
||||
{#if !application.settings.isBot}
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<Setting
|
||||
isCenter={false}
|
||||
bind:setting={previews}
|
||||
on:click={() => changeSettings('previews')}
|
||||
title={$t('application.enable_mr_pr_previews')}
|
||||
description={$t('application.enable_preview_deploy_mr_pr_requests')}
|
||||
/>
|
||||
</div>
|
||||
{/if}
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<Setting
|
||||
isCenter={false}
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
<div class="truncate text-center font-bold text-red-500 group-hover:text-white">
|
||||
Destination Missing
|
||||
</div>
|
||||
{:else if !application.fqdn}
|
||||
{:else if !application.fqdn && !application.settings.isBot}
|
||||
<div class="truncate text-center font-bold text-red-500 group-hover:text-white">
|
||||
URL Missing
|
||||
</div>
|
||||
|
||||
@@ -20,35 +20,38 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts">
|
||||
export let applications: any;
|
||||
export let databases: any;
|
||||
export let services: any;
|
||||
export let settings: any;
|
||||
|
||||
import { get, post } from '$lib/api';
|
||||
import Usage from '$lib/components/Usage.svelte';
|
||||
import { t } from '$lib/translations';
|
||||
import { errorNotification, asyncSleep } from '$lib/common';
|
||||
import { addToast, appSession } from '$lib/store';
|
||||
|
||||
|
||||
import ApplicationsIcons from '$lib/components/svg/applications/ApplicationIcons.svelte';
|
||||
import DatabaseIcons from '$lib/components/svg/databases/DatabaseIcons.svelte';
|
||||
import ServiceIcons from '$lib/components/svg/services/ServiceIcons.svelte';
|
||||
import { dev } from '$app/env';
|
||||
|
||||
let loading = {
|
||||
cleanup: false
|
||||
};
|
||||
|
||||
export let applications: any;
|
||||
export let databases: any;
|
||||
export let services: any;
|
||||
let numberOfGetStatus = 0;
|
||||
|
||||
function getRndInteger(min: number, max: number) {
|
||||
return Math.floor(Math.random() * (max - min + 1) ) + min;
|
||||
}
|
||||
let numberOfGetStatus = 0;
|
||||
|
||||
function getRndInteger(min: number, max: number) {
|
||||
return Math.floor(Math.random() * (max - min + 1)) + min;
|
||||
}
|
||||
|
||||
async function getStatus(resources: any) {
|
||||
while (numberOfGetStatus > 1){
|
||||
await asyncSleep(getRndInteger(100,200));
|
||||
while (numberOfGetStatus > 1) {
|
||||
await asyncSleep(getRndInteger(100, 200));
|
||||
}
|
||||
try {
|
||||
numberOfGetStatus++;
|
||||
numberOfGetStatus++;
|
||||
const { id, buildPack, dualCerts } = resources;
|
||||
let isRunning = false;
|
||||
if (buildPack) {
|
||||
@@ -69,8 +72,8 @@
|
||||
} catch (error) {
|
||||
return 'Error';
|
||||
} finally {
|
||||
numberOfGetStatus--;
|
||||
}
|
||||
numberOfGetStatus--;
|
||||
}
|
||||
}
|
||||
async function manuallyCleanupStorage() {
|
||||
try {
|
||||
@@ -98,40 +101,90 @@
|
||||
<div class="mx-auto px-10">
|
||||
<div class="flex flex-col justify-center xl:flex-row">
|
||||
{#if applications.length > 0}
|
||||
<div>
|
||||
<div class="title">Resources</div>
|
||||
<div class="flex items-start justify-center p-8">
|
||||
<table class="rounded-none text-base">
|
||||
<tbody>
|
||||
{#each applications as application}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(application)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
<div>
|
||||
<div class="title">Resources</div>
|
||||
<div class="flex items-start justify-center p-8">
|
||||
<table class="rounded-none text-base">
|
||||
<tbody>
|
||||
{#each applications as application}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(application)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{application.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<ApplicationsIcons {application} isAbsolute={false} />
|
||||
</td>
|
||||
<td class="px-10">
|
||||
<div
|
||||
class="badge badge-outline text-xs border-applications rounded text-white"
|
||||
>
|
||||
Application
|
||||
{#if application.settings.isBot}
|
||||
| BOT
|
||||
{/if}
|
||||
</div></td
|
||||
>
|
||||
<td class="flex justify-end">
|
||||
{#if application.fqdn}
|
||||
<a
|
||||
href={application.fqdn}
|
||||
target="_blank"
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
><svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" />
|
||||
<line x1="10" y1="14" x2="20" y2="4" />
|
||||
<polyline points="15 4 20 4 20 9" />
|
||||
</svg></a
|
||||
>
|
||||
{/if}
|
||||
{#if application.settings.isBot && application.exposePort}
|
||||
<a
|
||||
href={`http://${dev ? 'localhost' : settings.ipv4}:${
|
||||
application.exposePort
|
||||
}`}
|
||||
target="_blank"
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
><svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" />
|
||||
<line x1="10" y1="14" x2="20" y2="4" />
|
||||
<polyline points="15 4 20 4 20 9" />
|
||||
</svg></a
|
||||
>
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{application.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<ApplicationsIcons {application} isAbsolute={false} />
|
||||
</td>
|
||||
<td class="px-10">
|
||||
<div class="badge badge-outline text-xs border-applications rounded text-white">
|
||||
Application
|
||||
</div></td
|
||||
>
|
||||
<td class="flex justify-end">
|
||||
{#if application.fqdn}
|
||||
<a
|
||||
href={application.fqdn}
|
||||
target="_blank"
|
||||
href={`/applications/${application.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
><svg
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
@@ -142,72 +195,72 @@
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" />
|
||||
<line x1="10" y1="14" x2="20" y2="4" />
|
||||
<polyline points="15 4 20 4 20 9" />
|
||||
</svg></a
|
||||
>
|
||||
{/if}
|
||||
<a
|
||||
href={`/applications/${application.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
|
||||
{#each services as service}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(service)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
{#each services as service}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(service)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{service.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<ServiceIcons type={service.type} isAbsolute={false} />
|
||||
</td>
|
||||
<td class="px-10"
|
||||
><div class="badge badge-outline text-xs border-services rounded text-white">
|
||||
Service
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td class="flex justify-end">
|
||||
{#if service.fqdn}
|
||||
<a
|
||||
href={service.fqdn}
|
||||
target="_blank"
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
><svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" />
|
||||
<line x1="10" y1="14" x2="20" y2="4" />
|
||||
<polyline points="15 4 20 4 20 9" />
|
||||
</svg></a
|
||||
>
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{service.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<ServiceIcons type={service.type} isAbsolute={false} />
|
||||
</td>
|
||||
<td class="px-10"
|
||||
><div class="badge badge-outline text-xs border-services rounded text-white">
|
||||
Service
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td class="flex justify-end">
|
||||
{#if service.fqdn}
|
||||
<a
|
||||
href={service.fqdn}
|
||||
target="_blank"
|
||||
href={`/services/${service.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
><svg
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
@@ -218,97 +271,76 @@
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<path d="M11 7h-5a2 2 0 0 0 -2 2v9a2 2 0 0 0 2 2h9a2 2 0 0 0 2 -2v-5" />
|
||||
<line x1="10" y1="14" x2="20" y2="4" />
|
||||
<polyline points="15 4 20 4 20 9" />
|
||||
</svg></a
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
{#each databases as database}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(database)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{database.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<DatabaseIcons type={database.type} />
|
||||
</td>
|
||||
<td class="px-10">
|
||||
<div class="badge badge-outline text-xs border-databases rounded text-white">
|
||||
Database
|
||||
</div>
|
||||
</td>
|
||||
<td class="flex justify-end">
|
||||
<a
|
||||
href={`/databases/${database.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex ml-11"
|
||||
>
|
||||
{/if}
|
||||
<a
|
||||
href={`/services/${service.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex"
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
{#each databases as database}
|
||||
<tr>
|
||||
<td class="space-x-2 items-center tracking-tight font-bold">
|
||||
{#await getStatus(database)}
|
||||
<div class="inline-flex w-2 h-2 bg-yellow-500 rounded-full" />
|
||||
{:then status}
|
||||
{#if status === 'Running'}
|
||||
<div class="inline-flex w-2 h-2 bg-success rounded-full" />
|
||||
{:else}
|
||||
<div class="inline-flex w-2 h-2 bg-error rounded-full" />
|
||||
{/if}
|
||||
{/await}
|
||||
<div class="inline-flex">{database.name}</div>
|
||||
</td>
|
||||
<td class="px-10 inline-flex">
|
||||
<DatabaseIcons type={database.type} />
|
||||
</td>
|
||||
<td class="px-10">
|
||||
<div class="badge badge-outline text-xs border-databases rounded text-white">
|
||||
Database
|
||||
</div>
|
||||
</td>
|
||||
<td class="flex justify-end">
|
||||
<a
|
||||
href={`/databases/${database.id}`}
|
||||
class="icons bg-transparent text-sm inline-flex ml-11"
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
</tbody>
|
||||
</table>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-6 w-6"
|
||||
viewBox="0 0 24 24"
|
||||
stroke-width="1.5"
|
||||
stroke="currentColor"
|
||||
fill="none"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||
<rect x="4" y="8" width="4" height="4" />
|
||||
<line x1="6" y1="4" x2="6" y2="8" />
|
||||
<line x1="6" y1="12" x2="6" y2="20" />
|
||||
<rect x="10" y="14" width="4" height="4" />
|
||||
<line x1="12" y1="4" x2="12" y2="14" />
|
||||
<line x1="12" y1="18" x2="12" y2="20" />
|
||||
<rect x="16" y="5" width="4" height="4" />
|
||||
<line x1="18" y1="4" x2="18" y2="5" />
|
||||
<line x1="18" y1="9" x2="18" y2="20" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
{/each}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
{#if $appSession.teamId === '0'}
|
||||
<Usage />
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
let dualCerts = settings.dualCerts;
|
||||
let isAutoUpdateEnabled = settings.isAutoUpdateEnabled;
|
||||
let isDNSCheckEnabled = settings.isDNSCheckEnabled;
|
||||
|
||||
let DNSServers = settings.DNSServers;
|
||||
let minPort = settings.minPort;
|
||||
let maxPort = settings.maxPort;
|
||||
|
||||
@@ -105,6 +105,10 @@
|
||||
settings.minPort = minPort;
|
||||
settings.maxPort = maxPort;
|
||||
}
|
||||
if (DNSServers !== settings.DNSServers) {
|
||||
await post(`/settings`, { DNSServers });
|
||||
settings.DNSServers = DNSServers;
|
||||
}
|
||||
forceSave = false;
|
||||
return addToast({
|
||||
message: 'Configuration saved.',
|
||||
@@ -275,6 +279,17 @@
|
||||
on:click={() => changeSettings('isDNSCheckEnabled')}
|
||||
/>
|
||||
</div>
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<div class="flex-col">
|
||||
<div class="pt-2 text-base font-bold text-stone-100">
|
||||
Custom DNS servers
|
||||
</div>
|
||||
<Explainer text="You can specify a custom DNS server to verify your domains all over Coolify.<br><br>By default, the OS defined DNS servers are used." />
|
||||
</div>
|
||||
<div class="mx-auto flex-row items-center justify-center space-y-2">
|
||||
<input placeholder="1.1.1.1,8.8.8.8" bind:value={DNSServers} />
|
||||
</div>
|
||||
</div>
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<Setting
|
||||
dataTooltip={$t('setting.must_remove_domain_before_changing')}
|
||||
|
||||
Reference in New Issue
Block a user