Skip to content

Commit f723a49

Browse files
Rafael Travado FernándezRafael Travado Fernández
Rafael Travado Fernández
authored and
Rafael Travado Fernández
committed
Cambios nuevos en el server.js
1 parent 0144f3b commit f723a49

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

backend/src/server.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@ app.use('/avatars', express.static(path.join(__dirname, '..', 'public', 'avatars
3838
// Configuración para servir la aplicación React en producción
3939
if (process.env.NODE_ENV === 'production') {
4040
// Servir archivos estáticos desde la carpeta build de React
41-
app.use(express.static(path.join(__dirname, '../frontend/build')));
41+
app.use(express.static(path.join(__dirname, '../../frontend/build')));
4242

4343
// Manejar cualquier solicitud que no sea a las rutas API
4444
app.get('*', (req, res) => {
45-
res.sendFile(path.join(__dirname, '../frontend/build', 'index.html'));
45+
res.sendFile(path.join(__dirname, '../../frontend/build', 'index.html'));
4646
});
4747
}
4848

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"server": "nodemon backend/src/server.js",
99
"client": "npm start --prefix frontend",
1010
"dev": "concurrently \"npm run server\" \"npm run client\"",
11-
"build": "npm install && npm install --prefix frontend && npm run build --prefix frontend",
11+
"build": "CI=false npm install && npm install --prefix frontend && npm run build --prefix frontend",
1212
"heroku-postbuild": "NPM_CONFIG_PRODUCTION=false npm install --prefix frontend && npm run build --prefix frontend"
1313
},
1414
"keywords": ["task", "manager", "AI", "fullstack"],

0 commit comments

Comments
 (0)