9 lines
229 B
JavaScript
9 lines
229 B
JavaScript
import http from "http";
|
|
|
|
const port = Number(process.env.PORT ?? 8080);
|
|
http
|
|
.get(`http://localhost:${port}/api/config`, (res) => {
|
|
process.exit(res.statusCode === 200 ? 0 : 1);
|
|
})
|
|
.on("error", () => process.exit(1));
|