access all ec2 across region via lambda

0

I have lambda function for auto AWS AMI backup is it possible to execute lambda across the region for take automatic backup of all EC2 running on account.

One lambda function execution for all ec2 across region.

asked 5 years ago194 views
1 Answer
0

var ec2 = new aws.EC2();

to connect to another region you can use

var ec2 = new AWS.EC2({apiVersion: '2006-03-01', region: 'us-west-2'});

now you can use the aws-sdk in lambda.

answered 5 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions