new email
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
"@hapi/boom": "^9.1.0",
|
||||
"@ng-bootstrap/ng-bootstrap": "6.2.0",
|
||||
"@types/chart.js": "^2.9.16",
|
||||
"@QMI/qmi-cloud-common": "2.0.13",
|
||||
"@QMI/qmi-cloud-common": "2.0.15",
|
||||
"adal-angular4": "^4.0.12",
|
||||
"angular-bootstrap-md": "9.0.0",
|
||||
"animate.css": "^3.7.2",
|
||||
|
||||
@@ -297,13 +297,13 @@ async function rotateStorageAccountKey(provision, keyName = "key1") {
|
||||
let newKey = result.keys.find(k => k.keyName === keyName).value;
|
||||
console.log("AzureCLI# rotateStorageAccountKey - New Key:", storageAccountName, newKey);
|
||||
let outputs = provision.outputs;
|
||||
outputs["NEW_StorageAccount-AccessKey"] = newKey;
|
||||
outputs["NEW_StorageAccount-ConnectionString"] = `DefaultEndpointsProtocol=https;AccountName=${storageAccountName};AccountKey=${newKey};EndpointSuffix=core.windows.net`;
|
||||
await db.provision.update(provision._id, {"outputs": outputs});
|
||||
outputs["StorageAccount-AccessKey"] = newKey;
|
||||
outputs["StorageAccount-ConnectionString"] = `DefaultEndpointsProtocol=https;AccountName=${storageAccountName};AccountKey=${newKey};EndpointSuffix=core.windows.net`;
|
||||
const upProv = await db.provision.update(provision._id, {"outputs": outputs});
|
||||
|
||||
console.log(`AzureCLI# Done rotateStorageAccountKey!! - ${keyName} for ${storageAccountName}...`);
|
||||
|
||||
return outputs;
|
||||
return upProv;
|
||||
} catch (error) {
|
||||
console.log("AzureCLI# Error rotateStorageAccountKey:", error);
|
||||
return null;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@QMI/qmi-cloud-common",
|
||||
"version": "2.0.13",
|
||||
"version": "2.0.15",
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-ec2": "^3.590.0",
|
||||
"@aws-sdk/client-rds": "^3.590.0",
|
||||
|
||||
@@ -158,13 +158,13 @@ function getHtmlSharedProvision( provision, scenario) {
|
||||
function getHtmlRotateKeyProvision(provision, scenario) {
|
||||
var htmlint;
|
||||
if ( provision && provision.outputs ) {
|
||||
htmlint = `<div style="color:#404040;font-size:20px;padding: 10px 0px;">New Storage Account Details</div>`;
|
||||
htmlint = `<div style="color:#404040;font-size:20px;padding: 10px 0px;">New Storage Account Details:</div>`;
|
||||
htmlint += `<table style="width:100%" border="0">`;
|
||||
} else {
|
||||
htmlint = "";
|
||||
}
|
||||
for (let key in provision.outputs) {
|
||||
if (key.includes("NEW_")){
|
||||
if (key.includes("StorageAccount-")){
|
||||
htmlint += `<tr>
|
||||
<td style="padding-right: 15px"><b style="color:#404040">${key}</b></td>
|
||||
<td><pre style="color:#404040;">${provision.outputs[key]}</pre></td>
|
||||
@@ -177,21 +177,17 @@ function getHtmlRotateKeyProvision(provision, scenario) {
|
||||
}
|
||||
|
||||
var myFooter = getFooter(provision);
|
||||
var description = decodeURI(scenario.description);
|
||||
var common = `<div style="color:#404040;font-size:18px;margin:20px 0px">
|
||||
<p style="margin:0px">Provision information:</p>
|
||||
</div>
|
||||
<div>
|
||||
<span style="color:#404040">ID: </span> ${provision._id}
|
||||
<span style="color:#404040">Provision ID: </span> ${provision._id}
|
||||
</div>
|
||||
<div>
|
||||
<span style="color:#404040">Purpose: </span> ${provision.description}
|
||||
</div>
|
||||
<div>
|
||||
<span style="color:#404040">Scenario: </span> ${scenario.title}
|
||||
</div>
|
||||
<div>
|
||||
<span style="color:#404040">Description: </span> ${description}
|
||||
</div>`;
|
||||
|
||||
return `<div style="width:600px;color:black!important;font-family:'Source Sans Pro',sans-serif;padding:50px">
|
||||
@@ -200,7 +196,10 @@ function getHtmlRotateKeyProvision(provision, scenario) {
|
||||
<p style="margin:0px">QMI Cloud</p>
|
||||
</div>
|
||||
<div style="color:#404040;font-size:22px;margin:20px 0px">
|
||||
<p style="margin:0px">Scenario '${scenario.title}' - NEW Storage Account Access Key!</p>
|
||||
<p style="margin:0px">Scenario '${scenario.title}' - Storage Account Access Key!</p>
|
||||
</div>
|
||||
<div style="color:#404040;margin:20px 0px">
|
||||
<p style="margin:0px">In order to improve security, your Storage Account Access Key in this QMI scenario provision has been rotated. You may need to update your Storage Account connections with bellow new details.</p>
|
||||
</div>
|
||||
|
||||
${common}
|
||||
|
||||
Reference in New Issue
Block a user