
Product
Introducing Tier 1 Reachability: Precision CVE Triage for Enterprise Teams
Socket’s new Tier 1 Reachability filters out up to 80% of irrelevant CVEs, so security teams can focus on the vulnerabilities that matter.
@aerisweather/deploy-cloud-formation
Advanced tools
Easily deploy and update CloudFormation templates
When you pass a template to deployCloudFormation
:
So nothing too fancy. But it turns out that this is kind of tricky using the AWS SDK alone.
npm install --save-dev @aerisweather/deploy-cloud-formation
The simplest way to deploy a CloudFormation template is using the CLI tool:
node_modules/.bin/deploy-cloud-formation \
--template ./my-cloud-formation-template.json \
--stackName MyStack \
--region us-east-1
const deployCloudFormation = require('@aerisweather/deploy-cloud-formation').default;
const template = {
"Resources": {
"EC2Instance": {
"Type": "AWS::EC2::Instance",
"Properties": {
// ...
}
},
"InstanceSecurityGroup": {
"Type": "AWS::EC2::SecurityGroup",
"Properties": {
// ...
}
}
}
}
deployCloudFormation({
region: 'us-east-1',
template: JSON.stringify(template),
stackName: 'my-cloudformation-stack'
})
.then(
() => console.log(`Done!`),
(err) => console.error(`Failed to create a CloudFormation stack: ${err.message}`)
);
To make writing JSON templates a little nicer, we provide you with some utility functions:
import {Join, AccountId, Attr, Ref} from '@aeriweather/deploy-cloud-formation';
const template = {
Resources: {
//...
SomeRole: {
Type: 'AWS::IAM::Role',
Properties: {
ManagedPolicyArns: [
// Reference a policy ARN, using your AWS Account ID
Join([
'arn:aws:iam::',
AccountId(),
]),
// Reference a policy ARN, from the same CF template,
// using `Fn::Att`
Attr('SomePolicy', 'Arn'),
// Reference a policy ARN, from the same CF template,
// using `{ Ref }`
Ref('SomePolicy')
]
}
}
}
};
FAQs
Easily deploy and update CloudFormation templates
We found that @aerisweather/deploy-cloud-formation demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket’s new Tier 1 Reachability filters out up to 80% of irrelevant CVEs, so security teams can focus on the vulnerabilities that matter.
Research
/Security News
Ongoing npm supply chain attack spreads to DuckDB: multiple packages compromised with the same wallet-drainer malware.
Security News
The MCP Steering Committee has launched the official MCP Registry in preview, a central hub for discovering and publishing MCP servers.