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
# pull existing files down | |
rm -rf /tmp/cms | |
scp -i ~/.ssh/id_rsa_storage -rp storage@some_server_ip:/var/backups/mongodb/cms/ /tmp | |
# drop the mongo db | |
/usr/local/mongodb/bin/mongo --eval "db.dropDatabase()" cms | |
# restore your mongo db and collections | |
/usr/local/mongodb/bin/mongorestore -d cms --dir /tmp/cms |
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
# Guide | |
# Configure the essential configurations below and do the following: | |
# | |
# Repository Creation: | |
# cap deploy:repository:create | |
# git add . | |
# git commit -am "initial commit" | |
# git push origin master | |
# | |
# Initial Deployment: |
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
# open up mongodb port on iptables | |
require_recipe "iptables" | |
iptables_rule "port_mongodb" do | |
variables(:port => config[:port]) | |
end |
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
# mongo_template.rb | |
# remove unneeded defaults | |
run "rm public/index.html" | |
run "rm public/images/rails.png" | |
run "rm public/javascripts/controls.js" | |
run "rm public/javascripts/dragdrop.js" | |
run "rm public/javascripts/effects.js" | |
run "rm public/javascripts/prototype.js" |
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
mxmapp@chef:~$ ps aux | grep chef | |
root 935 0.0 4.5 37408 23020 ? Sl 07:56 0:04 /usr/bin/ruby1.8 /usr/bin/chef-client -d -c /etc/chef/client.rb -i 1800 -s 20 | |
root 2494 60.3 3.1 21348 16120 ? R 09:18 13:23 ruby /usr/bin/chef-indexer -d -c /etc/chef/indexer.rb | |
mxmapp 2744 0.0 0.1 3036 788 pts/0 R+ 09:40 0:00 grep --color=auto chef |
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
~$ date | |
Thu Nov 12 23:46:51 UTC 2009 | |
~$ sudo cp /usr/share/zoneinfo/EST /etc/localtime | |
~$ sudo ntpdate ntp.ubuntu.com | |
12 Nov 18:47:15 ntpdate[5012]: adjust time server 91.189.94.4 offset -0.002164 sec | |
~$ date | |
Thu Nov 12 18:47:17 EST 2009 |
NewerOlder