mana 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. data/.gitignore +18 -0
  2. data/Gemfile +4 -0
  3. data/LICENSE +22 -0
  4. data/README.md +29 -0
  5. data/Rakefile +2 -0
  6. data/cookbooks/monit/attributes/default.rb +13 -0
  7. data/cookbooks/monit/files/ubuntu/monit.default +11 -0
  8. data/cookbooks/monit/libraries/monitrc.rb +21 -0
  9. data/cookbooks/monit/recipes/default.rb +34 -0
  10. data/cookbooks/monit/recipes/ssh.rb +3 -0
  11. data/cookbooks/monit/templates/default/monitrc.erb +31 -0
  12. data/cookbooks/monit/templates/default/ssh.monit.conf.erb +7 -0
  13. data/cookbooks/nginx/attributes/default.rb +3 -0
  14. data/cookbooks/nginx/definitions/nginx_site.rb +15 -0
  15. data/cookbooks/nginx/recipes/default.rb +44 -0
  16. data/cookbooks/nginx/templates/default/default.conf.erb +11 -0
  17. data/cookbooks/nginx/templates/default/nginx.conf.erb +32 -0
  18. data/cookbooks/nginx/templates/default/nginx.monit.conf.erb +8 -0
  19. data/cookbooks/nginx/templates/default/nxdissite.erb +29 -0
  20. data/cookbooks/nginx/templates/default/nxensite.erb +38 -0
  21. data/cookbooks/postgresql/attributes/default.rb +5 -0
  22. data/cookbooks/postgresql/recipes/client.rb +5 -0
  23. data/cookbooks/postgresql/recipes/default.rb +2 -0
  24. data/cookbooks/postgresql/recipes/server.rb +25 -0
  25. data/cookbooks/postgresql/templates/default/pg_hba.conf.erb +4 -0
  26. data/cookbooks/postgresql/templates/default/postgresql.conf.erb +505 -0
  27. data/cookbooks/postgresql/templates/default/postgresql.monit.conf.erb +11 -0
  28. data/cookbooks/railsapp/attributes/default.rb +22 -0
  29. data/cookbooks/railsapp/recipes/default.rb +65 -0
  30. data/cookbooks/railsapp/templates/default/master.monit.conf.erb +8 -0
  31. data/cookbooks/railsapp/templates/default/site.conf.erb +62 -0
  32. data/cookbooks/railsapp/templates/default/unicorn-init.sh.erb +64 -0
  33. data/cookbooks/railsapp/templates/default/unicorn.rb.erb +37 -0
  34. data/cookbooks/railsapp/templates/default/worker.monit.conf.erb +8 -0
  35. data/lib/mana.rb +5 -0
  36. data/lib/mana/capistrano.rb +93 -0
  37. data/lib/mana/railtie.rb +7 -0
  38. data/lib/mana/version.rb +3 -0
  39. data/lib/tasks/mana.rake +9 -0
  40. data/mana.gemspec +21 -0
  41. data/templates/Vagrantfile +4 -0
  42. data/templates/config/deploy.rb +24 -0
  43. data/templates/config/deploy/vagrant.rb +7 -0
  44. metadata +136 -0
@@ -0,0 +1,24 @@
1
+ set :application, 'application' #TODO: change this to application name
2
+
3
+ set :repository, 'git@github.com:author/application.git' #TODO: change this to repository
4
+
5
+ set :default_stage, :vagrant
6
+
7
+ set :ruby_version, '1.9.3-p194'
8
+
9
+ set :postgresql, version: '9.1'
10
+
11
+ set :monit,
12
+ notify_email: 'admin@application.com', #TODO: change this to your email to receive monit alerts
13
+ poll_period: 30
14
+
15
+ set :run_list, %w(
16
+ recipe[monit]
17
+ recipe[monit::ssh]
18
+ recipe[postgresql]
19
+ recipe[nginx]
20
+ recipe[railsapp]
21
+ )
22
+
23
+ after 'deploy', 'deploy:restart_unicorn'
24
+ after 'deploy:restart', 'deploy:cleanup'
@@ -0,0 +1,7 @@
1
+ server '10.10.10.10', :web, :app, :db, primary: true
2
+
3
+ set :user, 'vagrant'
4
+ set :password, 'vagrant'
5
+
6
+ set :branch, 'master'
7
+ set :rails_env, 'production'
metadata ADDED
@@ -0,0 +1,136 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mana
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Ilia Ablamonov, Cloud Castle Inc.
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2012-06-01 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: capistrano
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: '0'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '0'
30
+ - !ruby/object:Gem::Dependency
31
+ name: roundsman
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ type: :runtime
39
+ prerelease: false
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ - !ruby/object:Gem::Dependency
47
+ name: capistrano_colors
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :runtime
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ description: Configuration management with Chef & Capistrano
63
+ email:
64
+ - ilia@flamefork.ru
65
+ executables: []
66
+ extensions: []
67
+ extra_rdoc_files: []
68
+ files:
69
+ - .gitignore
70
+ - Gemfile
71
+ - LICENSE
72
+ - README.md
73
+ - Rakefile
74
+ - cookbooks/monit/attributes/default.rb
75
+ - cookbooks/monit/files/ubuntu/monit.default
76
+ - cookbooks/monit/libraries/monitrc.rb
77
+ - cookbooks/monit/recipes/default.rb
78
+ - cookbooks/monit/recipes/ssh.rb
79
+ - cookbooks/monit/templates/default/monitrc.erb
80
+ - cookbooks/monit/templates/default/ssh.monit.conf.erb
81
+ - cookbooks/nginx/attributes/default.rb
82
+ - cookbooks/nginx/definitions/nginx_site.rb
83
+ - cookbooks/nginx/recipes/default.rb
84
+ - cookbooks/nginx/templates/default/default.conf.erb
85
+ - cookbooks/nginx/templates/default/nginx.conf.erb
86
+ - cookbooks/nginx/templates/default/nginx.monit.conf.erb
87
+ - cookbooks/nginx/templates/default/nxdissite.erb
88
+ - cookbooks/nginx/templates/default/nxensite.erb
89
+ - cookbooks/postgresql/attributes/default.rb
90
+ - cookbooks/postgresql/recipes/client.rb
91
+ - cookbooks/postgresql/recipes/default.rb
92
+ - cookbooks/postgresql/recipes/server.rb
93
+ - cookbooks/postgresql/templates/default/pg_hba.conf.erb
94
+ - cookbooks/postgresql/templates/default/postgresql.conf.erb
95
+ - cookbooks/postgresql/templates/default/postgresql.monit.conf.erb
96
+ - cookbooks/railsapp/attributes/default.rb
97
+ - cookbooks/railsapp/recipes/default.rb
98
+ - cookbooks/railsapp/templates/default/master.monit.conf.erb
99
+ - cookbooks/railsapp/templates/default/site.conf.erb
100
+ - cookbooks/railsapp/templates/default/unicorn-init.sh.erb
101
+ - cookbooks/railsapp/templates/default/unicorn.rb.erb
102
+ - cookbooks/railsapp/templates/default/worker.monit.conf.erb
103
+ - lib/mana.rb
104
+ - lib/mana/capistrano.rb
105
+ - lib/mana/railtie.rb
106
+ - lib/mana/version.rb
107
+ - lib/tasks/mana.rake
108
+ - mana.gemspec
109
+ - templates/Vagrantfile
110
+ - templates/config/deploy.rb
111
+ - templates/config/deploy/vagrant.rb
112
+ homepage: https://github.com/cloudcastle/mana
113
+ licenses: []
114
+ post_install_message:
115
+ rdoc_options: []
116
+ require_paths:
117
+ - lib
118
+ required_ruby_version: !ruby/object:Gem::Requirement
119
+ none: false
120
+ requirements:
121
+ - - ! '>='
122
+ - !ruby/object:Gem::Version
123
+ version: '0'
124
+ required_rubygems_version: !ruby/object:Gem::Requirement
125
+ none: false
126
+ requirements:
127
+ - - ! '>='
128
+ - !ruby/object:Gem::Version
129
+ version: '0'
130
+ requirements: []
131
+ rubyforge_project:
132
+ rubygems_version: 1.8.23
133
+ signing_key:
134
+ specification_version: 3
135
+ summary: Configuration management with Chef & Capistrano
136
+ test_files: []