provizioning 0.1.2 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (223) hide show
  1. data/.gitignore +17 -0
  2. data/Gemfile +4 -0
  3. data/README.md +29 -0
  4. data/Rakefile +2 -0
  5. data/bootstrap/bootstrap.sh +71 -0
  6. data/{lib/templates/sources.list → bootstrap/lucid.sources.list} +2 -1
  7. data/bootstrap/natty.sources.list +14 -0
  8. data/lib/provizioning/puppet.rb +94 -0
  9. data/lib/provizioning/version.rb +3 -0
  10. data/lib/provizioning.rb +1 -3
  11. data/provizioning.gemspec +20 -0
  12. data/puppet/classes/apache/centos.conf +978 -0
  13. data/puppet/classes/apache/ssl.conf +75 -0
  14. data/puppet/classes/apache.pp +152 -0
  15. data/puppet/classes/apt.pp +5 -0
  16. data/puppet/classes/base/ntp/ntpd-sysconfig +13 -0
  17. data/puppet/classes/base.pp +79 -0
  18. data/puppet/classes/freerange.pp +53 -0
  19. data/puppet/classes/gemrc/gemrc +9 -0
  20. data/puppet/classes/gemrc.pp +10 -0
  21. data/puppet/classes/imagemagick.pp +19 -0
  22. data/puppet/classes/iptables/load-iptables +3 -0
  23. data/puppet/classes/iptables/post-iptables +2 -0
  24. data/puppet/classes/iptables/pre-iptables +2 -0
  25. data/puppet/classes/iptables.pp +59 -0
  26. data/puppet/classes/logrotate/logrotate.erb +15 -0
  27. data/puppet/classes/logrotate.pp +37 -0
  28. data/puppet/classes/mongo/mongodb.conf +89 -0
  29. data/puppet/classes/mongo.pp +86 -0
  30. data/puppet/classes/monit/monit.conf +242 -0
  31. data/puppet/classes/monit.pp +39 -0
  32. data/puppet/classes/munin/plugins/passenger_memory_stats +123 -0
  33. data/puppet/classes/munin/plugins/passenger_status +130 -0
  34. data/puppet/classes/munin/plugins/rails_database_time +174 -0
  35. data/puppet/classes/munin/plugins/rails_request_duration +173 -0
  36. data/puppet/classes/munin/plugins/rails_request_error +169 -0
  37. data/puppet/classes/munin/plugins/rails_requests +175 -0
  38. data/puppet/classes/munin/plugins/rails_view_render_time +173 -0
  39. data/puppet/classes/munin/rails-plugin-config +4 -0
  40. data/puppet/classes/munin.pp +60 -0
  41. data/puppet/classes/mysql/password.erb +1 -0
  42. data/puppet/classes/mysql.pp +71 -0
  43. data/puppet/classes/openswan/ipsec.conf +17 -0
  44. data/puppet/classes/openswan/ipsec.secrets +1 -0
  45. data/puppet/classes/openswan/patched_ipsec_initd_script +223 -0
  46. data/puppet/classes/openswan/secret.erb +1 -0
  47. data/puppet/classes/openswan.pp +71 -0
  48. data/puppet/classes/post-flight.pp +17 -0
  49. data/puppet/classes/postfix/main.cf +39 -0
  50. data/puppet/classes/postfix.pp +16 -0
  51. data/puppet/classes/rack/centos/passenger.load.erb +5 -0
  52. data/puppet/classes/rack/ubuntu/passenger.conf.erb +6 -0
  53. data/puppet/classes/rack.pp +66 -0
  54. data/puppet/classes/redis/redis.conf.erb +187 -0
  55. data/puppet/classes/redis.pp +20 -0
  56. data/puppet/classes/sudo/sudoers +6 -0
  57. data/puppet/classes/sudo.pp +24 -0
  58. data/puppet/classes/syslogng/CentOS.cnf +61 -0
  59. data/puppet/classes/syslogng/Ubuntu.cnf +347 -0
  60. data/puppet/classes/syslogng.pp +146 -0
  61. data/puppet/classes/xml.pp +23 -0
  62. data/puppet/classes/yum.pp +6 -0
  63. data/puppet/classes/zsh.pp +5 -0
  64. data/puppet/modules/README +74 -0
  65. data/puppet/modules/cron/README +4 -0
  66. data/puppet/modules/cron/manifests/base.pp +26 -0
  67. data/puppet/modules/cron/manifests/crontabs.pp +11 -0
  68. data/puppet/modules/cron/manifests/init.pp +18 -0
  69. data/puppet/modules/drupal/Modulefile +7 -0
  70. data/puppet/modules/drupal/README +110 -0
  71. data/puppet/modules/drupal/manifests/absent.pp +25 -0
  72. data/puppet/modules/drupal/manifests/backup/absent.pp +23 -0
  73. data/puppet/modules/drupal/manifests/backup.pp +49 -0
  74. data/puppet/modules/drupal/manifests/conf.pp +23 -0
  75. data/puppet/modules/drupal/manifests/debug.pp +26 -0
  76. data/puppet/modules/drupal/manifests/disable.pp +22 -0
  77. data/puppet/modules/drupal/manifests/disableboot.pp +13 -0
  78. data/puppet/modules/drupal/manifests/drush.pp +20 -0
  79. data/puppet/modules/drupal/manifests/example42/backup.pp +8 -0
  80. data/puppet/modules/drupal/manifests/example42/monitor.pp +8 -0
  81. data/puppet/modules/drupal/manifests/example42.pp +25 -0
  82. data/puppet/modules/drupal/manifests/extra.pp +30 -0
  83. data/puppet/modules/drupal/manifests/firewall/absent.pp +19 -0
  84. data/puppet/modules/drupal/manifests/firewall.pp +24 -0
  85. data/puppet/modules/drupal/manifests/init.pp +54 -0
  86. data/puppet/modules/drupal/manifests/install.pp +20 -0
  87. data/puppet/modules/drupal/manifests/module.pp +37 -0
  88. data/puppet/modules/drupal/manifests/monitor/absent.pp +42 -0
  89. data/puppet/modules/drupal/manifests/monitor.pp +77 -0
  90. data/puppet/modules/drupal/manifests/package.pp +20 -0
  91. data/puppet/modules/drupal/manifests/params.pp +277 -0
  92. data/puppet/modules/drupal/manifests/site.pp +63 -0
  93. data/puppet/modules/drupal/manifests/theme.pp +33 -0
  94. data/puppet/modules/drupal/templates/variables_drupal.erb +62 -0
  95. data/puppet/modules/drupal/tests/absent.pp +1 -0
  96. data/puppet/modules/drupal/tests/backup.pp +1 -0
  97. data/puppet/modules/drupal/tests/debug.pp +1 -0
  98. data/puppet/modules/drupal/tests/disable.pp +1 -0
  99. data/puppet/modules/drupal/tests/disableboot.pp +1 -0
  100. data/puppet/modules/drupal/tests/firewall.pp +1 -0
  101. data/puppet/modules/drupal/tests/init.pp +1 -0
  102. data/puppet/modules/drupal/tests/monitor.pp +1 -0
  103. data/puppet/modules/hosts/README +0 -0
  104. data/puppet/modules/hosts/manifests/example42.pp +5 -0
  105. data/puppet/modules/hosts/manifests/init.pp +16 -0
  106. data/puppet/modules/hosts/templates/hosts.erb +11 -0
  107. data/puppet/modules/iptables/README +4 -0
  108. data/puppet/modules/iptables/files/iptables +19 -0
  109. data/puppet/modules/iptables/manifests/disable.pp +15 -0
  110. data/puppet/modules/iptables/manifests/init.pp +9 -0
  111. data/puppet/modules/iptables/manifests/redhat.pp +24 -0
  112. data/puppet/modules/mysql/Modulefile +7 -0
  113. data/puppet/modules/mysql/README +56 -0
  114. data/puppet/modules/mysql/manifests/absent.pp +12 -0
  115. data/puppet/modules/mysql/manifests/backup/example42.pp +8 -0
  116. data/puppet/modules/mysql/manifests/backup.pp +49 -0
  117. data/puppet/modules/mysql/manifests/client.pp +18 -0
  118. data/puppet/modules/mysql/manifests/conf.pp +23 -0
  119. data/puppet/modules/mysql/manifests/debug.pp +25 -0
  120. data/puppet/modules/mysql/manifests/disable.pp +13 -0
  121. data/puppet/modules/mysql/manifests/disableboot.pp +13 -0
  122. data/puppet/modules/mysql/manifests/example42.pp +25 -0
  123. data/puppet/modules/mysql/manifests/firewall.pp +23 -0
  124. data/puppet/modules/mysql/manifests/grant.pp +29 -0
  125. data/puppet/modules/mysql/manifests/init.pp +67 -0
  126. data/puppet/modules/mysql/manifests/monitor/example42.pp +8 -0
  127. data/puppet/modules/mysql/manifests/monitor.pp +77 -0
  128. data/puppet/modules/mysql/manifests/params.pp +240 -0
  129. data/puppet/modules/mysql/manifests/query.pp +30 -0
  130. data/puppet/modules/mysql/templates/grant.erb +6 -0
  131. data/puppet/modules/mysql/templates/query.erb +5 -0
  132. data/puppet/modules/mysql/templates/variables_mysql.erb +42 -0
  133. data/puppet/modules/network/README +4 -0
  134. data/puppet/modules/network/manifests/init.pp +13 -0
  135. data/puppet/modules/nginx/manifests/fcgi.pp +87 -0
  136. data/puppet/modules/nginx/manifests/init.pp +205 -0
  137. data/puppet/modules/nginx/templates/fcgi_site.erb +38 -0
  138. data/puppet/modules/nginx/templates/includes/fastcgi_params.erb +23 -0
  139. data/puppet/modules/nginx/templates/nginx.conf.erb +31 -0
  140. data/puppet/modules/passenger/manifests/init.pp +12 -0
  141. data/puppet/modules/passenger/templates/myapp +39 -0
  142. data/puppet/modules/php/README +26 -0
  143. data/puppet/modules/php/manifests/init.pp +42 -0
  144. data/puppet/modules/php/manifests/module.pp +22 -0
  145. data/puppet/modules/php/manifests/pear/module.pp +21 -0
  146. data/puppet/modules/php/manifests/pear.pp +20 -0
  147. data/puppet/modules/php/manifests/pecl/config.pp +19 -0
  148. data/puppet/modules/php/manifests/pecl/module.pp +44 -0
  149. data/puppet/modules/php/manifests/pecl.pp +8 -0
  150. data/puppet/modules/php/manifests/soap.pp +20 -0
  151. data/puppet/modules/postgres/Copyright +13 -0
  152. data/puppet/modules/postgres/manifests/database.pp +40 -0
  153. data/puppet/modules/postgres/manifests/init.pp +25 -0
  154. data/puppet/modules/postgres/manifests/role.pp +40 -0
  155. data/puppet/modules/ruby/files/install-ruby-stow +43 -0
  156. data/puppet/modules/ruby/manifests/init.pp +18 -0
  157. data/puppet/modules/rvm/files/install-system-rvm +2 -0
  158. data/puppet/modules/rvm/manifests/classes/dependencies.pp +24 -0
  159. data/puppet/modules/rvm/manifests/classes/passenger.pp +166 -0
  160. data/puppet/modules/rvm/manifests/classes/system.pp +33 -0
  161. data/puppet/modules/rvm/manifests/definitions/system_user.pp +13 -0
  162. data/puppet/modules/rvm/manifests/init.pp +2 -0
  163. data/puppet/modules/rvm/templates/passenger-apache.conf.erb +9 -0
  164. data/puppet/modules/ssh/README +4 -0
  165. data/puppet/modules/ssh/manifests/auth.pp +39 -0
  166. data/puppet/modules/ssh/manifests/auth.pp.good +340 -0
  167. data/puppet/modules/ssh/manifests/eal4.pp +69 -0
  168. data/puppet/modules/ssh/manifests/init.pp +74 -0
  169. data/puppet/modules/stow/manifests/init.pp +5 -0
  170. data/puppet/modules/sudo/files/sudoers +25 -0
  171. data/puppet/modules/sudo/manifests/init.pp +1 -0
  172. data/puppet/modules/sudo/manifests/install.pp +5 -0
  173. data/puppet/modules/sudo/manifests/sudoers.pp +14 -0
  174. data/puppet/modules/ufw/manifests/init.pp +12 -0
  175. data/puppet/modules/users/README +28 -0
  176. data/puppet/modules/users/manifests/adduser.pp +16 -0
  177. data/puppet/modules/users/manifests/admin.pp +11 -0
  178. data/puppet/modules/users/manifests/automount.pp +34 -0
  179. data/puppet/modules/users/manifests/deluser.pp +8 -0
  180. data/puppet/modules/users/manifests/example42.pp +16 -0
  181. data/puppet/modules/users/manifests/init.pp +31 -0
  182. data/puppet/modules/users/manifests/ldap.pp +114 -0
  183. data/puppet/modules/users/manifests/params.pp +84 -0
  184. data/puppet/modules/users/templates/ldap/ldap.conf.erb +13 -0
  185. data/puppet/modules/users/templates/ldap/nsswitch.conf.erb +23 -0
  186. data/puppet/modules/users/templates/ldap/openldap-ldap.conf.erb +8 -0
  187. data/puppet/modules/webmin/manifests/init.pp +31 -0
  188. data/puppet/roles/blank.pp +1 -0
  189. data/puppet/site.pp +8 -0
  190. metadata +235 -81
  191. data/README +0 -3
  192. data/bin/provizion +0 -52
  193. data/lib/policies/chef-client.rb +0 -37
  194. data/lib/policies/lamp.rb +0 -42
  195. data/lib/policies/passenger.rb +0 -44
  196. data/lib/recipes/apache.rb +0 -70
  197. data/lib/recipes/apache_conf.rb +0 -3
  198. data/lib/recipes/bundler.rb +0 -4
  199. data/lib/recipes/chef_client.rb +0 -11
  200. data/lib/recipes/curl.rb +0 -8
  201. data/lib/recipes/essential.rb +0 -4
  202. data/lib/recipes/git.rb +0 -15
  203. data/lib/recipes/imagemagick.rb +0 -8
  204. data/lib/recipes/mailserver.rb +0 -9
  205. data/lib/recipes/memcached.rb +0 -16
  206. data/lib/recipes/mysql.rb +0 -21
  207. data/lib/recipes/nginx/init.d +0 -63
  208. data/lib/recipes/nginx.rb +0 -25
  209. data/lib/recipes/passenger.rb +0 -67
  210. data/lib/recipes/php.rb +0 -8
  211. data/lib/recipes/postgresql.rb +0 -21
  212. data/lib/recipes/ruby_enterprise.rb +0 -24
  213. data/lib/recipes/rvm.rb +0 -25
  214. data/lib/recipes/sources.rb +0 -5
  215. data/lib/recipes/subversion.rb +0 -8
  216. data/lib/recipes/syslog.rb +0 -7
  217. data/lib/recipes/ufw.rb +0 -12
  218. data/lib/recipes/vim.rb +0 -8
  219. data/lib/recipes/webmin.rb +0 -17
  220. data/lib/templates/apache.conf.erb +0 -12
  221. data/lib/templates/my.cnf +0 -132
  222. data/lib/templates/passenger.conf +0 -11
  223. data/lib/templates/passenger.load +0 -1
@@ -1,16 +0,0 @@
1
- package :memcached_daemon, :provides => :memcached do
2
- description 'Memcached, a distributed memory object store'
3
- apt %w( memcached )
4
-
5
- post :install, "/etc/init.d/memcached start"
6
- post :install, "sudo ldconfig"
7
-
8
- verify do
9
- has_executable 'memcached'
10
- end
11
- end
12
-
13
- package :libmemcached do
14
- source 'http://download.tangent.org/libmemcached-0.25.tar.gz'
15
- requires :memcached_daemon
16
- end
data/lib/recipes/mysql.rb DELETED
@@ -1,21 +0,0 @@
1
- package :mysql, :provides => :database do
2
- description 'MySQL Database'
3
- apt %w( mysql-server mysql-client libmysqlclient-dev ) do
4
- transfer "#{File.dirname(__FILE__)}/../templates/my.cnf", '/etc/mysql/'
5
- end
6
-
7
- verify do
8
- has_executable 'mysql'
9
- end
10
- end
11
-
12
- package :mysql_driver, :provides => :ruby_database_driver do
13
- description 'Ruby MySQL database driver'
14
- gem 'mysql'
15
-
16
- verify do
17
- has_gem 'mysql'
18
- end
19
-
20
- requires :ruby_enterprise
21
- end
@@ -1,63 +0,0 @@
1
- #! /bin/sh
2
-
3
- ### BEGIN INIT INFO
4
- # Provides: nginx
5
- # Required-Start: $all
6
- # Required-Stop: $all
7
- # Default-Start: 2 3 4 5
8
- # Default-Stop: 0 1 6
9
- # Short-Description: starts the nginx web server
10
- # Description: starts nginx using start-stop-daemon
11
- ### END INIT INFO
12
-
13
-
14
- PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
15
- DAEMON=/usr/local/nginx/sbin/nginx
16
- NAME=nginx
17
- DESC=nginx
18
-
19
- test -x $DAEMON || exit 0
20
-
21
- # Include nginx defaults if available
22
- if [ -f /etc/default/nginx ] ; then
23
- . /etc/default/nginx
24
- fi
25
-
26
- set -e
27
-
28
- case "$1" in
29
- start)
30
- echo -n "Starting $DESC: "
31
- start-stop-daemon --start --quiet --pidfile /usr/local/nginx/logs/$NAME.pid \
32
- --exec $DAEMON -- $DAEMON_OPTS
33
- echo "$NAME."
34
- ;;
35
- stop)
36
- echo -n "Stopping $DESC: "
37
- start-stop-daemon --stop --quiet --pidfile /usr/local/nginx/logs/$NAME.pid \
38
- --exec $DAEMON
39
- echo "$NAME."
40
- ;;
41
- restart|force-reload)
42
- echo -n "Restarting $DESC: "
43
- start-stop-daemon --stop --quiet --pidfile \
44
- /usr/local/nginx/logs/$NAME.pid --exec $DAEMON
45
- sleep 1
46
- start-stop-daemon --start --quiet --pidfile \
47
- /usr/local/nginx/logs/$NAME.pid --exec $DAEMON -- $DAEMON_OPTS
48
- echo "$NAME."
49
- ;;
50
- reload)
51
- echo -n "Reloading $DESC configuration: "
52
- start-stop-daemon --stop --signal HUP --quiet --pidfile /usr/local/nginx/logs/$NAME.pid \
53
- --exec $DAEMON
54
- echo "$NAME."
55
- ;;
56
- *)
57
- N=/etc/init.d/$NAME
58
- echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
59
- exit 1
60
- ;;
61
- esac
62
-
63
- exit 0
data/lib/recipes/nginx.rb DELETED
@@ -1,25 +0,0 @@
1
- # =========
2
- # = Notes =
3
- # =========
4
-
5
- # The phusion guys have made it so that you can install nginx and passenger in one
6
- # fell swoop, it is for this reason and cleanliness that I haven't decided to install
7
- # nginx and passenger separately, otherwise nginx ends up being dependent on passenger
8
- # so that it can call --add-module within its configure statement - That in itself would
9
- # be strange.
10
-
11
- package :nginx, :provides => :webserver do
12
- puts "** Nginx installed by passenger gem **"
13
- requires :passenger
14
-
15
- push_text File.read(File.join(File.dirname(__FILE__), 'nginx', 'init.d')), "/etc/init.d/nginx", :sudo => true do
16
- post :install, "sudo chmod +x /etc/init.d/nginx"
17
- post :install, "sudo /usr/sbin/update-rc.d -f nginx defaults"
18
- post :install, "sudo /etc/init.d/nginx start"
19
- end
20
-
21
- verify do
22
- has_executable "/usr/local/nginx/sbin/nginx"
23
- has_file "/etc/init.d/nginx"
24
- end
25
- end
@@ -1,67 +0,0 @@
1
- package :passenger_gem do
2
- description 'Phusion Passenger (aka mod_rails)'
3
- version '3.0'
4
- gem 'passenger'
5
-
6
- verify do
7
- has_gem 'passenger'
8
- end
9
- end
10
-
11
- package :passenger_apache, :provides => :appserver do
12
- description "Installs and configures Passenger for use with apache webserver"
13
- # require the apache passenger module load/conf files before installation because of a sprinkle limitation.
14
- requires :apache, :passenger_gem, :passenger_module_load, :passenger_module_conf
15
-
16
- passenger_version = '2.2.15'
17
-
18
- noop do
19
- pre :install, 'passenger-install-apache2-module --auto'
20
- post :install, "sudo a2enmod passenger"
21
- post :install, 'echo "NameVirtualHost *:80" | sudo tee -a /etc/apache2/httpd.conf'
22
- # Restart apache to enable changes
23
- post :install, '/etc/init.d/apache2 restart'
24
- end
25
-
26
- verify do
27
- has_file "/usr/local/ruby-enterprise/lib/ruby/gems/1.8/gems/passenger-#{passenger_version}/ext/apache2/mod_passenger.so"
28
- end
29
- end
30
-
31
- package :passenger_module_load do
32
-
33
- description "Uploads the passenger module load configuration. -sprinkle currently does not allow multiple installers per package, that's why the configuration files have it's own packages"
34
- requires :apache, :passenger_gem
35
-
36
- #TODO: :render => true seems not to work? hello sprinkle?!
37
- passenger_version = '2.2.15'
38
- transfer "#{File.dirname(__FILE__)}/../templates/passenger.load", "/etc/apache2/mods-available/passenger.load", :render => true
39
-
40
- verify do
41
- has_file '/etc/apache2/mods-available/passenger.load'
42
- end
43
- end
44
-
45
- package :passenger_module_conf do
46
-
47
- description "Uploads the passenger module conf configuration. -sprinkle currently does not allow multiple installers per package, that's why the configuration files have it's own packages"
48
- requires :apache, :passenger_gem
49
-
50
- #TODO: :render => true seems not to work? hello sprinkle?!
51
- passenger_version = '2.2.15'
52
- transfer "#{File.dirname(__FILE__)}/../templates/passenger.conf", "/etc/apache2/mods-available/passenger.conf", :render => true
53
-
54
- verify do
55
- has_file '/etc/apache2/mods-available/passenger.conf'
56
- end
57
- end
58
-
59
- package :passenger_nginx, :provides => :appserver do
60
- description "Installs and configures Passenger for use with the awesome nginx webserver"
61
-
62
- requires :passenger_gem
63
-
64
- noop do
65
- pre :install, "passenger-install-nginx-module --auto --auto-download"
66
- end
67
- end
data/lib/recipes/php.rb DELETED
@@ -1,8 +0,0 @@
1
- package :php do
2
- description 'PHP Interpreter'
3
- apt 'php5 libapache2-mod-php5 php5-mysql php5-gd'
4
-
5
- verify do
6
- has_executable 'php'
7
- end
8
- end
@@ -1,21 +0,0 @@
1
- package :postgres, :provides => :database do
2
- description 'PostgreSQL database'
3
- apt %w( postgresql postgresql-client libpq-dev )
4
-
5
- verify do
6
- has_executable 'psql'
7
- end
8
-
9
- optional :postgresql_driver
10
- end
11
-
12
- package :postgresql_driver, :provides => :ruby_database_driver do
13
- description 'Ruby PostgreSQL database driver'
14
- gem 'postgres'
15
-
16
- verify do
17
- has_gem 'postgres'
18
- end
19
-
20
- requires :ruby_enterprise
21
- end
@@ -1,24 +0,0 @@
1
- package :ruby_enterprise do
2
- description 'Ruby Enterprise Edition'
3
- version '1.8.7-2010.02'
4
- REE_PATH = "/usr/local/ruby-enterprise"
5
-
6
- binaries = %w(erb gem irb rackup rails rake rdoc ree-version ri ruby testrb)
7
- source "http://rubyforge.org/frs/download.php/71096/ruby-enterprise-#{version}.tar.gz" do
8
- custom_install 'sudo ./installer --auto=/usr/local/ruby-enterprise'
9
- binaries.each {|bin| post :install, "ln -s #{REE_PATH}/bin/#{bin} /usr/local/bin/#{bin}" }
10
- end
11
-
12
- verify do
13
- has_directory install_path
14
- has_executable "#{REE_PATH}/bin/ruby"
15
- binaries.each {|bin| has_symlink "/usr/local/bin/#{bin}", "#{REE_PATH}/bin/#{bin}" }
16
- end
17
-
18
- requires :ree_dependencies
19
- end
20
-
21
- package :ree_dependencies do
22
- apt %w(zlib1g-dev libreadline5-dev libssl-dev)
23
- requires :build_essential
24
- end
data/lib/recipes/rvm.rb DELETED
@@ -1,25 +0,0 @@
1
- package :rvm do
2
- description "Ruby Version Manager"
3
-
4
- runner "bash < <( curl -L http://bit.ly/rvm-install-system-wide )" do
5
- push_text '[[ -s "/usr/local/lib/rvm" ]] && . "/usr/local/lib/rvm" # This loads RVM into a shell session.', '/root/.bashrc'
6
- end
7
-
8
- verify do
9
- has_executable "rvm"
10
- end
11
-
12
- #requires :rvm_ree
13
- end
14
-
15
- package :rvm_ree do
16
- description "REE in RVM"
17
-
18
- apt "vim" do
19
- pre :install, "rvm install ree"
20
- post :install, "rvm --default ree"
21
- end
22
-
23
- #verify do
24
- #end
25
- end
@@ -1,5 +0,0 @@
1
- package :ubuntu_sources do
2
- transfer File.dirname(__FILE__) + '/../templates/sources.list', '/etc/apt/sources.list', :sudo => true do
3
- post :install, 'apt-get update'
4
- end
5
- end
@@ -1,8 +0,0 @@
1
- package :subversion, :provides => :scm do
2
- description 'Subversion Version Control'
3
- apt 'subversion'
4
-
5
- verify do
6
- has_executable 'svn'
7
- end
8
- end
@@ -1,7 +0,0 @@
1
- package :syslog do
2
- apt 'sysklogd'
3
-
4
- verify do
5
- has_log '/sbin/syslogd'
6
- end
7
- end
data/lib/recipes/ufw.rb DELETED
@@ -1,12 +0,0 @@
1
- package :ufw, :provides => :firewall do
2
- description "UFW Firewall"
3
-
4
- apt "ufw" do
5
- post :install, "sudo ufw allow to 0.0.0.0/0 port 80"
6
- post :install, "sudo ufw allow to 0.0.0.0/0 port 443"
7
- post :install, "sudo ufw allow to 0.0.0.0/0 port 3000"
8
- post :install, "sudo ufw allow to 0.0.0.0/0 port 22"
9
- post :install, "sudo ufw allow to 0.0.0.0/0 port 25"
10
- post :install, "sudo ufw enable"
11
- end
12
- end
data/lib/recipes/vim.rb DELETED
@@ -1,8 +0,0 @@
1
- package :vim do
2
- description 'VIM Editor'
3
- apt "vim"
4
-
5
- verify do
6
- has_executable 'vim'
7
- end
8
- end
@@ -1,17 +0,0 @@
1
- package :webmin, :provides => :panel do
2
- description 'Webmin'
3
- version '1.510'
4
- requires :webmin_dependencies
5
-
6
- deb "http://prdownloads.sourceforge.net/webadmin/webmin_#{version}-2_all.deb"
7
-
8
- verify do
9
- has_file "/etc/webmin/start"
10
- end
11
- end
12
-
13
- package :webmin_dependencies do
14
- description 'Webmin dependencies'
15
- apt 'apt-show-versions perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl'
16
- end
17
-
@@ -1,12 +0,0 @@
1
- <VirtualHost *:80>
2
- ServerName <%= domain %>
3
- DocumentRoot <%= deploy_to %>/current/public
4
- RailsEnv <%= stage %>
5
- AllowEncodedSlashes on
6
- RewriteEngine On
7
- RewriteRule ^/$ /system/cache/index.html [QSA]
8
- RewriteRule ^([^.]+)$ /system/cache/$1.html [QSA]
9
- RewriteCond %{DOCUMENT_ROOT}/system/maintenance.html -f
10
- RewriteCond %{SCRIPT_FILENAME} !maintenance.html
11
- RewriteRule ^.*$ /system/maintenance.html [L]
12
- </VirtualHost>
data/lib/templates/my.cnf DELETED
@@ -1,132 +0,0 @@
1
- #
2
- # The MySQL database server configuration file.
3
- #
4
- # You can copy this to one of:
5
- # - "/etc/mysql/my.cnf" to set global options,
6
- # - "~/.my.cnf" to set user-specific options.
7
- #
8
- # One can use all long options that the program supports.
9
- # Run program with --help to get a list of available options and with
10
- # --print-defaults to see which it would actually understand and use.
11
- #
12
- # For explanations see
13
- # http://dev.mysql.com/doc/mysql/en/server-system-variables.html
14
-
15
- # This will be passed to all mysql clients
16
- # It has been reported that passwords should be enclosed with ticks/quotes
17
- # escpecially if they contain "#" chars...
18
- # Remember to edit /etc/mysql/debian.cnf when changing the socket location.
19
- [client]
20
- port = 3306
21
- socket = /var/run/mysqld/mysqld.sock
22
- default-character-set = utf8
23
-
24
- # Here is entries for some specific programs
25
- # The following values assume you have at least 32M ram
26
-
27
- # This was formally known as [safe_mysqld]. Both versions are currently parsed.
28
- [mysqld_safe]
29
- socket = /var/run/mysqld/mysqld.sock
30
- nice = 0
31
-
32
- [mysqld]
33
- #
34
- # * Basic Settings
35
- #
36
-
37
- #
38
- # * IMPORTANT
39
- # If you make changes to these settings and your system uses apparmor, you may
40
- # also need to also adjust /etc/apparmor.d/usr.sbin.mysqld.
41
- #
42
-
43
- character-set-server = utf8
44
- user = mysql
45
- socket = /var/run/mysqld/mysqld.sock
46
- port = 3306
47
- basedir = /usr
48
- datadir = /var/lib/mysql
49
- tmpdir = /tmp
50
- skip-external-locking
51
- #
52
- # Instead of skip-networking the default is now to listen only on
53
- # localhost which is more compatible and is not less secure.
54
- bind-address = 127.0.0.1
55
- #
56
- # * Fine Tuning
57
- #
58
- key_buffer = 16M
59
- max_allowed_packet = 16M
60
- thread_stack = 192K
61
- thread_cache_size = 8
62
- # This replaces the startup script and checks MyISAM tables if needed
63
- # the first time they are touched
64
- myisam-recover = BACKUP
65
- #max_connections = 100
66
- #table_cache = 64
67
- #thread_concurrency = 10
68
- #
69
- # * Query Cache Configuration
70
- #
71
- query_cache_limit = 1M
72
- query_cache_size = 16M
73
- #
74
- # * Logging and Replication
75
- #
76
- # Both location gets rotated by the cronjob.
77
- # Be aware that this log type is a performance killer.
78
- # As of 5.1 you can enable the log at runtime!
79
- #general_log_file = /var/log/mysql/mysql.log
80
- #general_log = 1
81
-
82
- log_error = /var/log/mysql/error.log
83
-
84
- # Here you can see queries with especially long duration
85
- #log_slow_queries = /var/log/mysql/mysql-slow.log
86
- #long_query_time = 2
87
- #log-queries-not-using-indexes
88
- #
89
- # The following can be used as easy to replay backup logs or for replication.
90
- # note: if you are setting up a replication slave, see README.Debian about
91
- # other settings you may need to change.
92
- #server-id = 1
93
- #log_bin = /var/log/mysql/mysql-bin.log
94
- expire_logs_days = 10
95
- max_binlog_size = 100M
96
- #binlog_do_db = include_database_name
97
- #binlog_ignore_db = include_database_name
98
- #
99
- # * InnoDB
100
- #
101
- # InnoDB is enabled by default with a 10MB datafile in /var/lib/mysql/.
102
- # Read the manual for more InnoDB related options. There are many!
103
- #
104
- # * Security Features
105
- #
106
- # Read the manual, too, if you want chroot!
107
- # chroot = /var/lib/mysql/
108
- #
109
- # For generating SSL certificates I recommend the OpenSSL GUI "tinyca".
110
- #
111
- # ssl-ca=/etc/mysql/cacert.pem
112
- # ssl-cert=/etc/mysql/server-cert.pem
113
- # ssl-key=/etc/mysql/server-key.pem
114
-
115
-
116
-
117
- [mysqldump]
118
- quick
119
- quote-names
120
- max_allowed_packet = 16M
121
-
122
- [mysql]
123
- #no-auto-rehash # faster start of mysql but no tab completition
124
-
125
- [isamchk]
126
- key_buffer = 16M
127
-
128
- #
129
- # * IMPORTANT: Additional settings that can override those from this file!
130
- # The files must end with '.cnf', otherwise they'll be ignored.
131
- #
132
- !includedir /etc/mysql/conf.d/
@@ -1,11 +0,0 @@
1
- <IfModule passenger_module>
2
- PassengerRoot /opt/ruby-enterprise-1.8.7-2010.01/lib/ruby/gems/1.8/gems/passenger-2.2.12
3
- PassengerRuby /opt/ruby-enterprise-1.8.7-2010.01/bin/ruby
4
-
5
- # Default value is 6 (2 is recommended for a 256 Mb of RAM VPS)
6
- PassengerMaxPoolSize 4
7
-
8
- # Default value is 300
9
- PassengerPoolIdleTime 6000
10
-
11
- </IfModule>
@@ -1 +0,0 @@
1
- LoadModule passenger_module /opt/ruby-enterprise-1.8.7-2010.01/lib/ruby/gems/1.8/gems/passenger-2.2.12/ext/apache2/mod_passenger.so