🛠️ Add backend health check endpoint to deployment script
This commit is contained in:
@@ -251,12 +251,12 @@ async function deployLocal(config) {
|
|||||||
if (!frontendHealthy) throw new Error('Frontend health check failed');
|
if (!frontendHealthy) throw new Error('Frontend health check failed');
|
||||||
console.log(' ✅ Frontend healthy');
|
console.log(' ✅ Frontend healthy');
|
||||||
|
|
||||||
|
console.log(' Checking backend...');
|
||||||
const backendHealthy = await healthCheck(
|
const backendHealthy = await healthCheck(
|
||||||
'localhost',
|
'localhost',
|
||||||
config.backendPort,
|
config.backendPort,
|
||||||
'/health'
|
'/health'
|
||||||
);
|
);
|
||||||
const backendHealthy = await healthCheck('localhost', config.backendPort);
|
|
||||||
// Backend might need more time
|
// Backend might need more time
|
||||||
if (!backendHealthy) throw new Error('Backend health check failed');
|
if (!backendHealthy) throw new Error('Backend health check failed');
|
||||||
console.log(' ✅ Backend healthy');
|
console.log(' ✅ Backend healthy');
|
||||||
|
|||||||
Reference in New Issue
Block a user