🛠️ Improve error message formatting for health check failures
This commit is contained in:
@@ -498,14 +498,21 @@ async function deploy() {
|
|||||||
console.log(' Checking frontend...');
|
console.log(' Checking frontend...');
|
||||||
const frontendHealthy = await healthCheck(sshConfig.host, config.port);
|
const frontendHealthy = await healthCheck(sshConfig.host, config.port);
|
||||||
if (!frontendHealthy) {
|
if (!frontendHealthy) {
|
||||||
throw new Error('Frontend health check failed - container is not responding');
|
throw new Error(
|
||||||
|
'Frontend health check failed - container is not responding'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
console.log(' ✅ Frontend healthy');
|
console.log(' ✅ Frontend healthy');
|
||||||
|
|
||||||
console.log(' Checking backend...');
|
console.log(' Checking backend...');
|
||||||
const backendHealthy = await healthCheck(sshConfig.host, config.backendPort);
|
const backendHealthy = await healthCheck(
|
||||||
|
sshConfig.host,
|
||||||
|
config.backendPort
|
||||||
|
);
|
||||||
if (!backendHealthy) {
|
if (!backendHealthy) {
|
||||||
throw new Error('Backend health check failed - container is not responding');
|
throw new Error(
|
||||||
|
'Backend health check failed - container is not responding'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
console.log(' ✅ Backend healthy');
|
console.log(' ✅ Backend healthy');
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user