mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
Fix wrong record name for dnsme
This commit is contained in:
@@ -243,7 +243,11 @@ export const orderCertificate = async (
|
||||
throw new Error("Unsupported challenge type");
|
||||
}
|
||||
|
||||
const recordName = `_acme-challenge.${authz.identifier.value}`; // e.g., "_acme-challenge.example.com"
|
||||
let recordName = `_acme-challenge.${authz.identifier.value}`; // e.g., "_acme-challenge.example.com"
|
||||
if (acmeCa.configuration.dnsProviderConfig.provider === AcmeDnsProvider.DNSMadeEasy) {
|
||||
// For DNS Made Easy, we don't need to provide the domain name in the record name.
|
||||
recordName = "_acme-challenge";
|
||||
}
|
||||
const recordValue = `"${keyAuthorization}"`; // must be double quoted
|
||||
|
||||
switch (acmeCa.configuration.dnsProviderConfig.provider) {
|
||||
|
||||
@@ -18,6 +18,7 @@ export const dnsMadeEasyInsertTxtRecord = async (
|
||||
credentials: { apiKey, secretKey }
|
||||
} = connection;
|
||||
|
||||
logger.info({ hostedZoneId, domain, value }, "Inserting TXT record for DNS Made Easy");
|
||||
try {
|
||||
await request.post(
|
||||
getDNSMadeEasyUrl(`/V2.0/dns/managed/${encodeURIComponent(hostedZoneId)}/records`),
|
||||
@@ -64,6 +65,7 @@ export const dnsMadeEasyDeleteTxtRecord = async (
|
||||
credentials: { apiKey, secretKey }
|
||||
} = connection;
|
||||
|
||||
logger.info({ hostedZoneId, domain, value }, "Deleting TXT record for DNS Made Easy");
|
||||
try {
|
||||
// First, list records to find the record ID
|
||||
const listRecordsResponse = await request.get<{
|
||||
|
||||
Reference in New Issue
Block a user