mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-18 08:03:30 +02:00
Add basic api unit. This unit will be responsible for providing all stf restful apis.
This commit is contained in:
@@ -51,6 +51,13 @@ module.exports = function(options) {
|
||||
})
|
||||
})
|
||||
|
||||
;['/api/*'].forEach(function(route) {
|
||||
app.all(route, function(req, res) {
|
||||
proxy.web(req, res, {
|
||||
target: options.apiUrl
|
||||
})
|
||||
})
|
||||
})
|
||||
app.use(function(req, res) {
|
||||
proxy.web(req, res, {
|
||||
target: options.appUrl
|
||||
|
||||
Reference in New Issue
Block a user