19 lines
369 B
JavaScript
19 lines
369 B
JavaScript
"use strict";
|
|
|
|
const express = require("express");
|
|
|
|
const app = express();
|
|
const PORT = process.env.PORT || 3000;
|
|
|
|
app.use(express.json());
|
|
|
|
app.get("/health", (_req, res) => {
|
|
res.json({ status: "ok" });
|
|
});
|
|
|
|
app.listen(PORT, () => {
|
|
// Registrar puerto para facilitar el seguimiento en logs.
|
|
console.log(`Servidor escuchando en http://localhost:${PORT}`);
|
|
});
|
|
|