I know how to build little Sinatra apps in a service oriented way because of the books I am reading. What I am not clear about is how to host them. If each one is its own self-contained app, how to I host them together? I am coming from a Rails mindset.
Asked
Active
Viewed 49 times
1 Answers
1
I would recomend to host each app it self when they not from the same project.
But if belong together you can use URLMap
# config.ru
run Rack::URLMap.new("/" => App.new,
"/api" => Api.new)
Or you can use Sinatra's middleware feature
# config.ru
...
use MyAppA
use MyAppB
use MyAppC
run MyAppD

Community
- 1
- 1

Sir l33tname
- 4,026
- 6
- 38
- 49