in resources/add_tenant_infra_lambda/handler.js [364:385]
async function createTenantCert(event) {
const {
body: {
tenantSubDomain,
tenantEmailDomain,
},
tenantuuid,
addTenantConfigResult: { baseParams },
} = event;
const hostedZoneId = getParameterValue('hostedzoneid', baseParams);
console.log(`hostedzoneid is ${hostedZoneId}`);
console.log(`Going to get a ACM public certificate for ${tenantSubDomain}`);
const cert = await getDnsValidatedCertificate(
tenantSubDomain,
hostedZoneId,
tenantuuid,
tenantEmailDomain,
);
console.log(`Done creating ACM public certificate for ${tenantSubDomain}: ${JSON.stringify(cert)}`);
return { cert };
}