Permalink
Browse files

Update stager to use new staging gem.

Change-Id: I49f571bf7630a48401bb6e9aa46bf0ff2a1655b1
  • Loading branch information...
1 parent ec30e94 commit 57a0c66ac0347824903c52299de46963f20f5d40 mpage committed Aug 16, 2011
Showing with 120 additions and 2,974 deletions.
  1. +1 −1 cloud_controller/config/initializers/staging.rb
  2. +15 −2 cloud_controller/script/run_plugin.rb
  3. BIN cloud_controller/vendor/cache/vcap_staging-0.1.0.gem
  4. +1 −1 lib/services/api/messages.rb
  5. +1 −3 stager/Gemfile
  6. +2 −8 stager/Gemfile.lock
  7. +1 −1 stager/bin/run_plugin
  8. +0 −1 stager/lib/vcap/stager.rb
  9. +0 −11 stager/lib/vcap/stager/plugin.rb
  10. +0 −561 stager/lib/vcap/stager/plugin/common.rb
  11. +0 −44 stager/lib/vcap/stager/plugin/gem_cache.rb
  12. +0 −86 stager/lib/vcap/stager/plugin/gemfile_support.rb
  13. +0 −282 stager/lib/vcap/stager/plugin/gemfile_task.rb
  14. +0 −89 stager/lib/vcap/stager/plugin/grails/plugin.rb
  15. +0 −7 stager/lib/vcap/stager/plugin/grails/stage
  16. BIN stager/lib/vcap/stager/plugin/java_common/resources/auto-reconfiguration-0.6.0-BUILD-SNAPSHOT.jar
  17. +0 −16 stager/lib/vcap/stager/plugin/java_common/resources/autostaging_template_grails.xml
  18. +0 −16 stager/lib/vcap/stager/plugin/java_common/resources/autostaging_template_spring.xml
  19. +0 −2 stager/lib/vcap/stager/plugin/java_common/resources/droplet.yaml
  20. +0 −60 stager/lib/vcap/stager/plugin/java_common/resources/generate_server_xml
  21. +0 −15 stager/lib/vcap/stager/plugin/java_common/resources/set_environment
  22. BIN stager/lib/vcap/stager/plugin/java_common/resources/tomcat.zip
  23. +0 −193 stager/lib/vcap/stager/plugin/java_common/tomcat.rb
  24. +0 −123 stager/lib/vcap/stager/plugin/lift/plugin.rb
  25. +0 −7 stager/lib/vcap/stager/plugin/lift/stage
  26. +0 −22 stager/lib/vcap/stager/plugin/manifests/grails.yml
  27. +0 −20 stager/lib/vcap/stager/plugin/manifests/lift.yml
  28. +0 −12 stager/lib/vcap/stager/plugin/manifests/node.yml
  29. +0 −12 stager/lib/vcap/stager/plugin/manifests/otp_rebar.yml
  30. +0 −3 stager/lib/vcap/stager/plugin/manifests/platform.yml
  31. +0 −35 stager/lib/vcap/stager/plugin/manifests/rails3.yml
  32. +0 −37 stager/lib/vcap/stager/plugin/manifests/sinatra.yml
  33. +0 −22 stager/lib/vcap/stager/plugin/manifests/spring.yml
  34. +0 −50 stager/lib/vcap/stager/plugin/node/plugin.rb
  35. +0 −5 stager/lib/vcap/stager/plugin/node/stage
  36. +0 −120 stager/lib/vcap/stager/plugin/otp_rebar/plugin.rb
  37. +0 −60 stager/lib/vcap/stager/plugin/otp_rebar/runtime_info.yml
  38. +0 −5 stager/lib/vcap/stager/plugin/otp_rebar/stage
  39. +0 −78 stager/lib/vcap/stager/plugin/rails3/database_support.rb
  40. +0 −93 stager/lib/vcap/stager/plugin/rails3/plugin.rb
  41. +0 −8 stager/lib/vcap/stager/plugin/rails3/stage
  42. +0 −61 stager/lib/vcap/stager/plugin/sinatra/plugin.rb
  43. +0 −5 stager/lib/vcap/stager/plugin/sinatra/stage
  44. +0 −70 stager/lib/vcap/stager/plugin/spring/plugin.rb
  45. +0 −7 stager/lib/vcap/stager/plugin/spring/stage
  46. +1 −1 stager/lib/vcap/stager/task.rb
  47. +0 −15 stager/spec/functional/disabled_frameworks_spec.rb
  48. +0 −77 stager/spec/functional/grails_spec.rb
  49. +0 −127 stager/spec/functional/lift_spec.rb
  50. +0 −69 stager/spec/functional/rails3_spec.rb
  51. +0 −27 stager/spec/functional/sinatra_spec.rb
  52. +0 −355 stager/spec/functional/spring_spec.rb
  53. +1 −2 stager/spec/spec_helper.rb
  54. +0 −1 stager/spec/support/java_staging_helpers.rb
  55. +0 −14 stager/spec/support/staging_spec_helpers.rb
  56. BIN stager/vendor/cache/active_support-3.0.0.gem
  57. BIN stager/vendor/cache/activesupport-3.0.0.gem
  58. BIN stager/vendor/cache/i18n-0.6.0.gem
  59. BIN stager/vendor/cache/nokogiri-1.5.0.gem
  60. BIN stager/vendor/cache/vcap_staging-0.1.0.gem
  61. +2 −0 staging/Gemfile
  62. +24 −0 staging/Gemfile.lock
  63. +58 −14 staging/lib/vcap/staging/plugin/common.rb
  64. 0 {stager/lib/vcap/stager → staging/lib/vcap/staging}/plugin/config.rb
  65. +12 −16 staging/spec/spec_helper.rb
  66. +1 −2 staging/spec/support/staging_spec_helpers.rb
  67. BIN staging/vendor/cache/daemons-1.1.4.gem
  68. BIN staging/vendor/cache/eventmachine-0.12.10.gem
  69. BIN staging/vendor/cache/json_pure-1.5.3.gem
  70. BIN staging/vendor/cache/little-plugger-1.1.2.gem
  71. BIN staging/vendor/cache/logging-1.5.2.gem
  72. BIN staging/vendor/cache/nats-0.4.10.gem
  73. BIN staging/vendor/cache/posix-spawn-0.3.6.gem
  74. BIN staging/vendor/cache/rack-1.3.2.gem
  75. BIN staging/vendor/cache/thin-1.2.11.gem
  76. BIN staging/vendor/cache/vcap_common-0.99.gem
@@ -1,7 +1,7 @@
require 'secure_user_manager'
require 'vcap/staging/plugin/common'
-ENV['STAGING_CONFIG_DIR'] = AppConfig[:directories][:staging_manifests]
+StagingPlugin.manifest_root = AppConfig[:directories][:staging_manifests]
# Activates the staging plugins and loads all included YAML files
StagingPlugin.load_all_manifests
@@ -4,6 +4,8 @@
require 'rubygems'
require 'bundler/setup'
+require 'yajl'
+
require 'vcap/staging/plugin/common'
unless ARGV.length > 0
@@ -12,6 +14,17 @@
end
name = ARGV.shift
+args = ARGV.dup
+
+if args.length > 2
+ begin
+ args[2] = Yajl::Parser.parse(args[2], :symbolize_keys => true)
+ rescue => e
+ puts "ERROR DECODING ENVIRONMENT: #{e}"
+ exit 1
+ end
+end
+
plugin_class = StagingPlugin.load_plugin_for(name)
-plugin_class.validate_arguments!
-plugin_class.new(*ARGV).stage_application
+plugin_class.validate_arguments!(*args)
+plugin_class.new(*args).stage_application
Binary file not shown.
@@ -37,7 +37,7 @@ class HandleUpdateRequest < JsonMessage
end
class ListHandlesResponse < JsonMessage
- required :handles, [JsonSchema::WILDCARD]
+ required :handles, [::JsonSchema::WILDCARD]
end
#
View
@@ -1,16 +1,14 @@
source :rubygems
-gem 'active_support'
-gem 'i18n' # Active support apparently requires this but it isn't in the Gemfile??
gem 'nats'
-gem 'nokogiri', '>= 1.4.4'
gem 'rake'
gem 'redis'
gem 'resque'
gem 'yajl-ruby', '>= 0.7.9'
gem 'vcap_common', :path => '../common'
gem 'vcap_logging', '>= 0.1.1'
+gem 'vcap_staging'
group :test do
gem 'rspec'
View
@@ -12,15 +12,11 @@ PATH
GEM
remote: http://rubygems.org/
specs:
- active_support (3.0.0)
- activesupport (= 3.0.0)
- activesupport (3.0.0)
addressable (2.2.6)
crack (0.1.8)
daemons (1.1.4)
diff-lcs (1.1.2)
eventmachine (0.12.10)
- i18n (0.6.0)
json (1.5.3)
json_pure (1.5.3)
little-plugger (1.1.2)
@@ -30,7 +26,6 @@ GEM
daemons (>= 1.1.0)
eventmachine (>= 0.12.10)
json_pure (>= 1.5.1)
- nokogiri (1.5.0)
posix-spawn (0.3.6)
rack (1.3.2)
rake (0.9.2)
@@ -59,6 +54,7 @@ GEM
rack (>= 1.0.0)
tilt (1.3.2)
vcap_logging (0.1.1)
+ vcap_staging (0.1.0)
vegas (0.1.8)
rack (>= 1.0.0)
webmock (1.6.4)
@@ -70,16 +66,14 @@ PLATFORMS
ruby
DEPENDENCIES
- active_support
- i18n
nats
- nokogiri (>= 1.4.4)
rake
redis
resque
rspec
sinatra
vcap_common!
vcap_logging (>= 0.1.1)
+ vcap_staging
webmock
yajl-ruby (>= 0.7.9)
@@ -5,7 +5,7 @@ require 'bundler/setup'
$LOAD_PATH.unshift(File.expand_path('../../lib', __FILE__))
-require 'vcap/stager/plugin'
+require 'vcap/staging/plugin/common'
unless ARGV.length == 2
puts "Usage: run_staging_plugin [plugin name] [plugin config file]"
@@ -3,7 +3,6 @@
require 'vcap/stager/errors'
require 'vcap/stager/config'
-require 'vcap/stager/plugin'
require 'vcap/stager/task'
require 'vcap/stager/task_logger'
require 'vcap/stager/task_result'
@@ -1,11 +0,0 @@
-require 'vcap/stager/plugin/gem_cache'
-require 'vcap/stager/plugin/gemfile_support'
-require 'vcap/stager/plugin/gemfile_task'
-require 'vcap/stager/plugin/common'
-require 'vcap/stager/plugin/grails/plugin'
-require 'vcap/stager/plugin/lift/plugin'
-require 'vcap/stager/plugin/node/plugin'
-require 'vcap/stager/plugin/otp_rebar/plugin'
-require 'vcap/stager/plugin/rails3/plugin'
-require 'vcap/stager/plugin/sinatra/plugin'
-require 'vcap/stager/plugin/spring/plugin'
Oops, something went wrong.

0 comments on commit 57a0c66

Please sign in to comment.