fix
This commit is contained in:
parent
a267ee40d2
commit
17badf95dc
@ -137,6 +137,7 @@ export async function parseAndFindServiceTemplates(service: any, workdir?: strin
|
||||
const extras = variable?.extras
|
||||
if (envValue.startsWith('$$config') || extras?.isVisibleOnUI) {
|
||||
if (envValue.startsWith('$$config_coolify')) {
|
||||
continue
|
||||
console.log({ envValue, envKey })
|
||||
}
|
||||
parsedTemplate[realKey].environment.push(
|
||||
@ -180,6 +181,9 @@ export async function parseAndFindServiceTemplates(service: any, workdir?: strin
|
||||
if (service.serviceSetting.length > 0) {
|
||||
for (const setting of service.serviceSetting) {
|
||||
const { value, variableName } = setting
|
||||
if (variableName.startsWith('$$config_coolify')) {
|
||||
continue;
|
||||
}
|
||||
if (service.fqdn && value === '$$generate_fqdn') {
|
||||
strParsedTemplate = strParsedTemplate.replaceAll(variableName, service.fqdn)
|
||||
} else if (service.fqdn && value === '$$generate_domain') {
|
||||
|
@ -54,7 +54,9 @@
|
||||
let nonWWWDomain = service.fqdn && getDomain(service.fqdn).replace(/^www\./, '');
|
||||
let isNonWWWDomainOK = false;
|
||||
let isWWWDomainOK = false;
|
||||
|
||||
let secondaryFQDNs = service.serviceSetting.filter((setting) =>
|
||||
setting.name.startsWith('COOLIFY_FQDN')
|
||||
);
|
||||
async function isDNSValid(domain: any, isWWW: any) {
|
||||
try {
|
||||
await get(`/services/${id}/check?domain=${domain}`);
|
||||
@ -308,13 +310,12 @@
|
||||
required
|
||||
/>
|
||||
</div>
|
||||
{#each Object.keys(template) as oneService}
|
||||
{#each template[oneService].environment.filter( (a) => a.name.startsWith('COOLIFY_FQDN_') ) as variable}
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<label class="h-10" for={variable.name}>{variable.label || variable.name}</label>
|
||||
<input class="w-full" name={variable.name} id={variable.name} value={variable.value} />
|
||||
</div>
|
||||
{/each}
|
||||
{#each secondaryFQDNs as fqdn}
|
||||
{JSON.stringify(fqdn)}
|
||||
<div class="grid grid-cols-2 items-center">
|
||||
<label class="h-10" for={fqdn.name}>{fqdn.label || fqdn.name}</label>
|
||||
<input class="w-full" name={fqdn.name} id={fqdn.name} value={fqdn.value} />
|
||||
</div>
|
||||
{/each}
|
||||
</div>
|
||||
{#if forceSave}
|
||||
@ -399,7 +400,7 @@
|
||||
</div>
|
||||
<div class="grid grid-flow-row gap-2 px-4">
|
||||
{#if template[oneService].environment.length > 0}
|
||||
{#each template[oneService].environment.filter((a) => !a.name.startsWith('COOLIFY_FQDN_')) as variable}
|
||||
{#each template[oneService].environment as variable}
|
||||
<div class="grid grid-cols-2 items-center gap-2">
|
||||
<label class="h-10" for={variable.name}>{variable.label || variable.name}</label>
|
||||
{#if variable.defaultValue === '$$generate_fqdn'}
|
||||
|
Loading…
x
Reference in New Issue
Block a user