From 63af2f03c75f8aa424c59d7f71421276f72ad0a5 Mon Sep 17 00:00:00 2001 From: manupanand Date: Fri, 15 Nov 2024 12:31:45 +0530 Subject: [PATCH] test server deploy --- app.log | 6 ++++++ backend/server.js | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/app.log b/app.log index d64f066..05dfe9b 100644 --- a/app.log +++ b/app.log @@ -29,3 +29,9 @@ {"level":"\u001b[32minfo\u001b[39m","message":"{\"method\":\"GET\",\"url\":\"/favicon.ico\",\"status\":\"404\",\"responseTime\":\"2.722\"}","timestamp":"2024-11-13T10:20:59.439Z"} {"level":"\u001b[32minfo\u001b[39m","message":"Server started succesfully on port :5000","timestamp":"2024-11-14T17:18:50.576Z"} {"level":"\u001b[32minfo\u001b[39m","message":"MongoDb connection successful","timestamp":"2024-11-14T17:18:51.239Z"} +{"level":"\u001b[32minfo\u001b[39m","message":"Server started succesfully on port :5000","timestamp":"2024-11-14T17:23:51.346Z"} +{"level":"\u001b[32minfo\u001b[39m","message":"MongoDb connection successful","timestamp":"2024-11-14T17:23:52.045Z"} +{"level":"\u001b[31merror\u001b[39m","message":"Error in creating User / Signup controller: username is not defined","stack":"ReferenceError: username is not defined\n at signUpUser (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/backend/controllers/auth.controller.js:65:49)\n at Layer.handle [as handle_request] (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/layer.js:95:5)\n at next (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/route.js:149:13)\n at Route.dispatch (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/route.js:119:3)\n at Layer.handle [as handle_request] (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/layer.js:95:5)\n at /home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/index.js:284:15\n at Function.process_params (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/index.js:346:12)\n at next (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/index.js:280:10)\n at Function.handle (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/index.js:175:3)\n at router (/home/manudev/Documents/Codes/fullstack_projects/websocket/chat-application-websocket/node_modules/express/lib/router/index.js:47:12)","timestamp":"2024-11-14T17:23:54.891Z"} +{"level":"\u001b[32minfo\u001b[39m","message":"{\"method\":\"POST\",\"url\":\"/api/auth/signup\",\"status\":\"500\",\"responseTime\":\"33.379\"}","timestamp":"2024-11-14T17:23:54.896Z"} +{"level":"\u001b[32minfo\u001b[39m","message":"Server started succesfully on port :5000","timestamp":"2024-11-15T07:01:22.020Z"} +{"level":"\u001b[32minfo\u001b[39m","message":"MongoDb connection successful","timestamp":"2024-11-15T07:01:22.663Z"} diff --git a/backend/server.js b/backend/server.js index 347ab16..057dd5c 100644 --- a/backend/server.js +++ b/backend/server.js @@ -23,6 +23,12 @@ app.use(express.json())//to parse req.body middleware //routes app.use('/api/auth',mainRouter) app.use('/api/message',messageRouter) +app.get('/',(req,res)=>{ + res.json({ + message:"got main route test", + malay:"തിരഞ്ഞെടുത്ത ഉദ്ധരണി " + }) +}) app.listen(5000,()=>{