diff --git a/backend/src/index.ts b/backend/src/index.ts index 28751a3..76e4124 100644 --- a/backend/src/index.ts +++ b/backend/src/index.ts @@ -55,11 +55,11 @@ async function main() { }); // Routes - app.use("/api/auth", authRoutes); - app.use("/api/clients", clientRoutes); - app.use("/api/projects", projectRoutes); - app.use("/api/time-entries", timeEntryRoutes); - app.use("/api/timer", timerRoutes); + app.use("/auth", authRoutes); + app.use("/clients", clientRoutes); + app.use("/projects", projectRoutes); + app.use("/time-entries", timeEntryRoutes); + app.use("/timer", timerRoutes); // Error handling app.use(notFoundHandler); diff --git a/frontend/nginx.conf b/frontend/nginx.conf index f3f975b..1a30e15 100644 --- a/frontend/nginx.conf +++ b/frontend/nginx.conf @@ -7,29 +7,4 @@ server { location / { try_files $uri $uri/ /index.html; } - - # Proxy API requests to backend - location /api { - proxy_pass http://backend:3001; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection 'upgrade'; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_cache_bypass $http_upgrade; - } - - location /auth { - proxy_pass http://backend:3001; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection 'upgrade'; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_cache_bypass $http_upgrade; - } } \ No newline at end of file