DockerRestApi/routes/status.js

17 lines
401 B
JavaScript
Raw Normal View History

2019-09-19 16:07:12 +00:00
var express = require('express'),
request = require('request');
var router = express.Router();
router.get('/', function (req, res, next) {
request('http://www.google.com', function (error, response, body) {
console.log('error:', error);
console.log('statusCode:', response && response.statusCode);
console.log('body:', body);
res.send(body);
});
});
module.exports = router;