add API monitor
This commit is contained in:
parent
3098d054c5
commit
9e030e764c
|
|
@ -211,7 +211,7 @@ Route.get('/api/images/:filename', "ImagesController.getImage");
|
|||
|
||||
Route.get('/api/monitor', async ({ request, response }) => {
|
||||
try {
|
||||
await Database.raw("SELECT 1")
|
||||
console.log(await Database.raw("SELECT 1"))
|
||||
response.status(200).send("I'm fine!")
|
||||
} catch (error) {
|
||||
response.status(203).send("Can't connect to database!")
|
||||
|
|
|
|||
Loading…
Reference in New Issue