Skip to content

Commit 66412a3

Browse files
authored
Update app.js
Updated
1 parent ad0e9b4 commit 66412a3

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

app.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ const bodyParser = require('body-parser');
33
const cors = require('cors'); // Added CORS support
44

55
const app = express();
6-
const PORT = process.env.PORT || 3000;
6+
const PORT = process.env.PORT || 5000;
7+
const DOMAIN = '20.48.204.5';
78

89
app.use(cors()); // Enable CORS for frontend communication
910
app.use(bodyParser.json());
@@ -53,7 +54,7 @@ app.post('/api/details', (req, res) => {
5354
res.json({ detail: detailed_knowledge[index] });
5455
});
5556

56-
// Start the server
57-
app.listen(PORT, () => {
58-
console.log(`Server running on port ${PORT}`);
57+
// Start the server on the specified domain and port
58+
app.listen(PORT, DOMAIN, () => {
59+
console.log(`Server running on http://${DOMAIN}:${PORT}`);
5960
});

0 commit comments

Comments
 (0)