1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

feature #1370: make sunstone server compatible with rackup

This commit is contained in:
Javi Fontan 2013-03-05 15:55:49 +01:00
parent a4a6f566ca
commit 7d73610eb7
2 changed files with 14 additions and 1 deletions

12
src/sunstone/config.ru Executable file
View File

@ -0,0 +1,12 @@
# If you are using self contained installation set this variable to the
# install location
#ENV['ONE_LOCATION']='/path/to/OpenNebula/install'
WITH_RACKUP=true
$: << '.'
require 'sunstone-server'
run Sinatra::Application

View File

@ -408,4 +408,5 @@ post '/:resource/:id/action' do
request.body.read)
end
Sinatra::Application.run!
Sinatra::Application.run! if(!defined?(WITH_RACKUP))