chore: фронт :3107, API :3001 (Docker, Vite, CORS, доки)
- compose: testing-web 3107:80, testing-backend 3001:3001, PORT+FRONTEND_URL - nginx → testing-backend:3001; Vite 3107, proxy /api → 3001 - server default PORT 3001; Dockerfile EXPOSE 3001; CORS dev — localhost:3107 - README, журнал, user guide Made-with: Cursor
This commit is contained in:
+1
-2
@@ -16,9 +16,8 @@ export function createApp() {
|
||||
? [process.env.FRONTEND_URL]
|
||||
: []
|
||||
: [
|
||||
'http://localhost:5173',
|
||||
'http://localhost:3107',
|
||||
'http://localhost:3000',
|
||||
'http://localhost:8080',
|
||||
];
|
||||
app.use(
|
||||
cors({
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { createApp } from './app.js';
|
||||
|
||||
const app = createApp();
|
||||
const PORT = process.env.PORT || 3107;
|
||||
const PORT = process.env.PORT || 3001;
|
||||
app.listen(PORT, () => {
|
||||
console.log(`Server is running on port ${PORT}`);
|
||||
console.log(`Environment: ${process.env.NODE_ENV || 'development'}`);
|
||||
|
||||
Reference in New Issue
Block a user