2020-12-30 22:19:12 +01:00
|
|
|
exports.default = async function(configuration) {
|
2020-12-31 17:28:44 +01:00
|
|
|
//console.log(`config:\n${JSON.stringify(configuration, null, 4)}`)
|
2020-12-31 18:33:33 +01:00
|
|
|
console.log(`env test - secret test ${process.env.SECRET_TEST}`)
|
2021-01-05 15:22:01 +01:00
|
|
|
console.log(`env test - shouldn't work ${process.env.secretTest}`)
|
2020-12-30 22:19:12 +01:00
|
|
|
|
|
|
|
require("child_process").execSync(
|
2020-12-31 23:09:00 +01:00
|
|
|
`azuresigntool sign -kvu ${process.env.SIGNING_VAULT_URL} -kvi ${process.env.SIGNING_CLIENT_ID} -kvt ${process.env.SIGNING_TENANT_ID} -kvs ${process.env.SIGNING_CLIENT_SECRET} -kvc ${process.env.SIGNING_CERT_NAME} -fd ${configuration.hash} -du ${configuration.site} -tr http://timestamp.digicert.com ${configuration.path}`,
|
2020-12-30 22:19:12 +01:00
|
|
|
{
|
|
|
|
stdio: "inherit"
|
|
|
|
}
|
|
|
|
);
|
|
|
|
};
|