Last active
June 30, 2017 04:30
-
-
Save anuragmathur1/5f26ed3b14ae6e2ea510678198985106 to your computer and use it in GitHub Desktop.
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
aws ec2 create-network-interface --description some-internal --groups sg-xxxxxxxx --subnet-id subnet-xxxxxxxx --profile=work | |
aws ec2 create-tags --resources eni-xxxxxxxx --tags Key=Name,Value=some-internal Key=appType,Value=logging --profile=work | |
aws ec2 run-instances --image-id ami-xxxxxxxx --instance-type t2.medium --security-group-ids sg-xxxxxxxx --subnet-id subnet-xxxxxxxx --iam-instance-profile Arn=arn:aws:iam::123456789876:instance-profile/my-instance-profile --tag-specifications 'ResourceType=instance,Tags=[{Key=Name,Value=elk},{Key=appType,Value=elk}]' 'ResourceType=volume,Tags=[{Key=Name,Value=some-app-host},{Key=appType,Value=some-app}]' --profile=work | |
aws ec2 attach-network-interface --device-index 1 --instance-id i-xxxxxxxxxxxxxxxxx --network-interface-id eni-xxxxxxxx | |
#aws ec2 describe-network-interfaces --filters Name=tag:Name,Values=some-app* | |
#aws ec2 describe-instances --profile=work --filters Name=tag:Name,Values=some-app* --query 'Reservations[*].Instances[*].[InstanceId]' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment