mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-09 22:28:25 +00:00
Log, add query for nock
This commit is contained in:
@@ -319,6 +319,7 @@ Feature: External CA
|
|||||||
"scope": "https://api.dnsmadeeasy.com:443",
|
"scope": "https://api.dnsmadeeasy.com:443",
|
||||||
"method": "GET",
|
"method": "GET",
|
||||||
"path": "/V2.0/dns/managed/MOCK_ZONE_ID/records",
|
"path": "/V2.0/dns/managed/MOCK_ZONE_ID/records",
|
||||||
|
"query": {"type": "TXT", "recordName": "_acme-challenge"},
|
||||||
"status": 200,
|
"status": 200,
|
||||||
"response": {
|
"response": {
|
||||||
"totalRecords": 1,
|
"totalRecords": 1,
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export const dnsMadeEasyInsertTxtRecord = async (
|
|||||||
credentials: { apiKey, secretKey }
|
credentials: { apiKey, secretKey }
|
||||||
} = connection;
|
} = connection;
|
||||||
|
|
||||||
logger.info({ hostedZoneId, domain }, "Inserting TXT record for DNS Made Easy");
|
logger.info({ hostedZoneId, domain, value }, "Inserting TXT record for DNS Made Easy");
|
||||||
try {
|
try {
|
||||||
await request.post(
|
await request.post(
|
||||||
getDNSMadeEasyUrl(`/V2.0/dns/managed/${encodeURIComponent(hostedZoneId)}/records`),
|
getDNSMadeEasyUrl(`/V2.0/dns/managed/${encodeURIComponent(hostedZoneId)}/records`),
|
||||||
@@ -66,7 +66,7 @@ export const dnsMadeEasyDeleteTxtRecord = async (
|
|||||||
credentials: { apiKey, secretKey }
|
credentials: { apiKey, secretKey }
|
||||||
} = connection;
|
} = connection;
|
||||||
|
|
||||||
logger.info({ zoneId: hostedZoneId, domain }, "Deleting TXT record for DNS Made Easy");
|
logger.info({ hostedZoneId, domain, value }, "Deleting TXT record for DNS Made Easy");
|
||||||
try {
|
try {
|
||||||
const dnsRecords = await listDNSMadeEasyRecords(connection, { zoneId: hostedZoneId, type: "TXT", name: domain });
|
const dnsRecords = await listDNSMadeEasyRecords(connection, { zoneId: hostedZoneId, type: "TXT", name: domain });
|
||||||
|
|
||||||
@@ -90,7 +90,7 @@ export const dnsMadeEasyDeleteTxtRecord = async (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!foundRecord) {
|
if (!foundRecord) {
|
||||||
logger.warn({ zoneId: hostedZoneId, domain, value }, "Record to delete not found");
|
logger.warn({ hostedZoneId, domain, value }, "Record to delete not found");
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (axios.isAxiosError(error)) {
|
if (axios.isAxiosError(error)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user