This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Engaged | Not Engaged | ||
---|---|---|---|
High Infra Interest | Flexible framework stored with app | DevOps preference but give access to suggest changes | |
Low Infra Interest | Opinionated framework stored with app | DevOps preference but give view acess |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Common | Real special | ||
---|---|---|---|
Very strict | Use an opinionated but transparent framework | Use a flexible transparent framework | |
Relaxed | Pick an framework with an example of your stack | Use the framework you have spent the most time in |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: 0.1 | |
phases: | |
install: | |
commands: | |
- sudo apt-get update -y | |
- sudo apt-get install -y wget | |
- sudo apt-get install -y gdebi | |
- wget https://packages.chef.io/stable/ubuntu/12.04/chefdk_1.0.3-1_amd64.deb | |
- gdebi -n chefdk_1.0.3-1_amd64.deb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: 0.1 | |
environment_variables: | |
plaintext: | |
key: "value" | |
key: "value" | |
phases: | |
install: | |
commands: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Version": "2012-10-17", | |
"Statement": [{ | |
"Action": ["logs:CreateLogGroup", | |
"logs:CreateLogStream", | |
"logs:PutLogEvents"], | |
"Resource": ["*"], | |
"Effect": "Allow", | |
"Sid": "Stmt1476220637000" | |
}] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Effect": "Allow", | |
"Principal": { | |
"Service": "lambda.amazonaws.com" | |
}, | |
"Action": "sts:AssumeRole" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import logging | |
# Setup cloud watch logging | |
logger.setLevel(logging.WARNING) | |
# Create boto3 EC2 resource | |
ec2 = boto3.resource('ec2') | |
def lambda_handler(event, context): | |
logger = logging.getLogger() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(Get-EC2Instance -filter @( @{name='tag:Name';values="*Webserver*"})).instances | where {$_.InstanceType -eq "t2.micro"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(Get-EC2Instance -filter @( @{name='tag:Name';values="*Webserver*"})).instances |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import boto3 | |
# Create boto3 ec2 resource | |
ec2 = boto3.resource('ec2') | |
# Retrieve instances with a name tag that contains Webserver | |
filters = [{'Name':'tag:instanceSchedule', 'Values': ['*Webserver*']}] | |
instances = ec2.instances.filter(Filters=filters) |
NewerOlder