Last active
August 29, 2015 14:17
-
-
Save nathenharvey/2aca1ac8f28b3836be63 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
--- | |
driver: | |
name: ec2 | |
aws_ssh_key_id: <%= ENV['AWS_KEYPAIR_NAME'] %> | |
transport.ssh_key: <%= ENV['AWS_KEY_PATH'] %> | |
provisioner: | |
name: chef_zero | |
platforms: | |
- name: centos-6.4 | |
driver: | |
image_id: ami-0fd22064 | |
availability_zone: us-east-1c | |
tags: | |
class: intro-to-chef | |
name: intro-to-chef | |
remove_after: '2015-06-16' | |
security_group_ids: ['sg-16899172'] | |
<% number_of_students = 40 %> | |
<% count_of_instances = 0 %> | |
suites: | |
<% | |
%w[ ♣︎ ♠︎ ♥︎ ♦︎ ].each do |suit| | |
%w[ A K Q J 10 9 8 7 6 5 4 3 2].each do |symbol| | |
if count_of_instances < number_of_students %> | |
- name: <%= symbol %><%= suit %> | |
<% count_of_instances +=1 %> | |
<% end %> | |
<% end %> | |
<% end %> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
number_of_students
kitchen create
knife
with this command:knife ec2 server list --region $AWS_REGION -A $AWS_ACCESS_KEY_ID -K $AWS_SECRET_ACCESS_KEY |grep $AWS_KEYPAIR_NAME | grep ami-3605295e | grep running |awk '{print $2}'
kitchen destroy