knife cookbook site vendor wordpress -d
Demonstration the different parts of the cookbook.
metadata.rb - Show the dependencies and explain how the -d worked.
default.rb - Show how this recipe installs wordpress and includes all the other cookbooks.
name "wordpress"
description "simple blog app"
run_list(
"recipe[wordpress]"
)
knife role from file wordpress.rb
for i in wordpress php apache2 mysql openssl
do
knife cookbook upload $i
done
Command version
for i in wordpress php apache2 mysql openssl; do knife cookbook upload $i; done
###Launch the Wordpress Blog
knife ec2 server create "role[wordpress]" -f m1.small -i ami-480df921 -G default,wordpress -S botchagalupe -x ubuntu -I ~/chef-repo/.chef/botchaglupe.pem
or
knife bootstrap PUBLICHOSTNAME -i ~/chef-repo/.chef/botchagalupe.pem -x ubuntu --sudo -r 'role[wordpress]'