mirror of
https://github.com/ArthurDanjou/artdanj-api.git
synced 2026-01-27 10:00:27 +01:00
Working on auth
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import Route from "@ioc:Adonis/Core/Route";
|
||||
|
||||
Route.group(() => {
|
||||
Route.get('/me', 'AuthController.user').middleware('auth')
|
||||
Route.get('/me', 'AuthController.user')
|
||||
Route.post('/token', 'AuthController.createInfiniteToken')
|
||||
|
||||
Route.group(() => {
|
||||
|
||||
@@ -26,7 +26,7 @@ Route.get('/source', async ({response}: HttpContextContract) => {
|
||||
Route.get('/health', async ({response}: HttpContextContract) => {
|
||||
const report = await HealthCheck.getReport()
|
||||
const isLive = await HealthCheck.isLive()
|
||||
const isReady = await HealthCheck.isReady()
|
||||
const isReady = HealthCheck.isReady()
|
||||
return report.healthy ? response.ok({isLive, isReady, report: report.report}) : response.badRequest({
|
||||
isLive,
|
||||
isReady,
|
||||
|
||||
Reference in New Issue
Block a user