Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Last revision Both sides next revision | ||
linux_wiki:lambda_python_function [2019/08/02 23:01] billdozor [File Conversion Example: Packaging] |
linux_wiki:lambda_python_function [2019/08/09 22:20] billdozor [File Conversion Example: Pre-Reqs] |
||
---|---|---|---|
Line 18: | Line 18: | ||
See below for Lambda examples. | See below for Lambda examples. | ||
* File Conversion Example - convert images from one format to another when created in a S3 bucket. | * File Conversion Example - convert images from one format to another when created in a S3 bucket. | ||
+ | * Stop/Start EC2 Instances Example - stop/start ec2 instances with a certain tag key:value on a schedule. | ||
Line 54: | Line 55: | ||
---- | ---- | ||
+ | |||
+ | ===== Stop/Start EC2 Example: Pre-Reqs ===== | ||
+ | |||
+ | Create an IAM role | ||
+ | * Services > Security > IAM > Roles > Create Role | ||
+ | * Choose a service that will use the role: Lambda | ||
+ | * Click ' | ||
+ | * **Required**: | ||
+ | * Also, Create a new policy to allow basic EC2 list, | ||
+ | " | ||
+ | " | ||
+ | { | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | " | ||
+ | ], | ||
+ | " | ||
+ | } | ||
+ | ] | ||
+ | }</ | ||
+ | |||
+ | ---- | ||
+ | |||
====== Lambda: Create Function ====== | ====== Lambda: Create Function ====== |