Permalink
Browse files

fix template paths, fix Gemfile appending

  • Loading branch information...
1 parent 5002e92 commit ea77de30e70a4700c750061e60ffa72d77572610 Matt Conway committed Dec 30, 2011
Showing with 9 additions and 6 deletions.
  1. +3 −3 bin/rubber
  2. 0 {lib/generators/vulcanize → }/templates/base/config/rubber/common/rsyslog.conf
  3. +5 −2 templates/base/templates.rb
  4. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/deploy-collectd.rb
  5. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/role/collectd/collectd.conf
  6. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/role/collectd/filters.conf
  7. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/role/collectd/thresholds.conf
  8. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/role/collectd/types.db
  9. 0 .../generators/vulcanize → }/templates/collectd/config/rubber/role/passenger/collectd-passenger.conf
  10. 0 ...nerators/vulcanize → }/templates/collectd/config/rubber/role/passenger/collectd-passenger.rb.conf
  11. 0 ...ators/vulcanize → }/templates/collectd/config/rubber/role/passenger/passenger-status-sudoers.conf
  12. 0 ...enerators/vulcanize → }/templates/collectd/config/rubber/role/postgresql/collectd-postgresql.conf
  13. 0 ...ize → }/templates/collectd/config/rubber/role/postgresql_slave/collectd-postgresql-threshold.conf
  14. 0 {lib/generators/vulcanize → }/templates/collectd/config/rubber/rubber-collectd.yml
  15. 0 {lib/generators/vulcanize → }/templates/collectd/script/collectd/collectd-runner.rb
  16. 0 {lib/generators/vulcanize → }/templates/collectd/script/collectd/role/examples/example_db_query.rb
  17. 0 {lib/generators/vulcanize → }/templates/collectd/script/collectd/role/examples/example_simple.rb
  18. 0 ...tors/vulcanize → }/templates/collectd/script/collectd/role/postgresql_slave/replication_status.rb
  19. 0 {lib/generators/vulcanize → }/templates/collectd/script/collectd/role/redis/redis_info.rb
  20. 0 ...rators/vulcanize → }/templates/collectd/script/collectd/role/resque_worker/global_worker_stats.rb
  21. 0 ...nerators/vulcanize → }/templates/collectd/script/collectd/role/resque_worker/host_worker_stats.rb
  22. 0 ...tors/vulcanize → }/templates/collectd/script/collectd/role/resque_worker/resque_jobs_processed.rb
  23. 0 {lib/generators/vulcanize → }/templates/collectd/templates.yml
  24. 0 ...ulcanize → }/templates/complete_passenger_nginx/config/rubber/role/haproxy/haproxy-passenger.conf
  25. 0 {lib/generators/vulcanize → }/templates/complete_passenger_nginx/config/rubber/rubber-complete.yml
  26. 0 {lib/generators/vulcanize → }/templates/complete_passenger_nginx/templates.rb
  27. 0 {lib/generators/vulcanize → }/templates/complete_passenger_nginx/templates.yml
  28. 0 {lib/generators/vulcanize → }/templates/complete_passenger_nginx_mysql/templates.yml
  29. 0 {lib/generators/vulcanize → }/templates/complete_passenger_nginx_postgresql/templates.yml
  30. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/deploy-graphite.rb
  31. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/collectd/graphite-collectd.conf
  32. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_server/carbon.conf
  33. 0 ...s/vulcanize → }/templates/graphite/config/rubber/role/graphite_server/graphite-collectd-ping.conf
  34. 0 ...nerators/vulcanize → }/templates/graphite/config/rubber/role/graphite_server/storage-schemas.conf
  35. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_web/crontab
  36. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_web/dashboard.conf
  37. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_web/graphite-vhost.conf
  38. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_web/graphite.wsgi
  39. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/role/graphite_web/local_settings.py
  40. 0 {lib/generators/vulcanize → }/templates/graphite/config/rubber/rubber-graphite.yml
  41. 0 {lib/generators/vulcanize → }/templates/graphite/templates.yml
  42. 0 {lib/generators/vulcanize → }/templates/minimal_passenger_nginx/config/rubber/rubber-complete.yml
  43. 0 {lib/generators/vulcanize → }/templates/minimal_passenger_nginx/templates.yml
  44. 0 {lib/generators/vulcanize → }/templates/passenger_nginx/config/rubber/deploy-passenger_nginx.rb
  45. 0 ...ators/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/application.conf
  46. 0 {lib/generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/crontab
  47. 0 ...ators/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/monit-nginx.conf
  48. 0 ...nize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/munin-passenger-memory.conf
  49. 0 ...ize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/munin-passenger-sudoers.conf
  50. 0 ...s/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/munin-passenger.conf
  51. 0 {lib/generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/nginx
  52. 0 .../generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/nginx.conf
  53. 0 ...s/vulcanize → }/templates/passenger_nginx/config/rubber/role/passenger_nginx/passenger_nginx.conf
  54. 0 .../generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/web_tools/nginx-tools.conf
  55. 0 .../generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/web_tools/tools-index.html
  56. 0 .../generators/vulcanize → }/templates/passenger_nginx/config/rubber/role/web_tools/tools-nginx.auth
  57. 0 {lib/generators/vulcanize → }/templates/passenger_nginx/config/rubber/rubber-passenger_nginx.yml
  58. 0 {lib/generators/vulcanize → }/templates/passenger_nginx/templates.yml
  59. 0 {lib/generators/vulcanize → }/templates/postgresql/config/rubber/role/postgresql_slave/recovery.conf
  60. +1 −1 templates/resque/templates.rb
View
@@ -1,10 +1,10 @@
#!/usr/bin/env ruby
-
env = ENV['RUBBER_ENV'] ||= 'development'
root = '.'
-
-if File.exists?("Gemfile")
+# Only load gemfile if there and contains rubber in order
+# to allow vulcanize to work in bootstrap case
+if File.exists?("Gemfile") && File.read("Gemfile").lines.grep(/gem.*["']rubber["']/).size > 0
require "bundler"
Bundler.setup(:default, env.to_sym)
end
@@ -1,7 +1,10 @@
if Rubber::Util::is_bundler?
- gem "rubber", Rubber.version if ! Rubber::Util::rubber_as_plugin?
+ if ! Rubber::Util::rubber_as_plugin?
+ append_to_file "Gemfile", "gem 'rubber', '#{Rubber.version}'\n"
+ end
+
# for cron-sh
- gem "open4"
+ append_to_file 'Gemfile', "gem 'open4'\n"
end
if Rubber::Util::is_rails2?
@@ -1 +1 @@
-gem "resque" if Rubber::Util::is_bundler?
+append_to_file 'Gemfile', "gem 'resque'\n" if Rubber::Util::is_bundler?

0 comments on commit ea77de3

Please sign in to comment.