Created
December 26, 2023 14:22
-
-
Save duttaANI/c307043429cd9a18996a0cca2656a828 to your computer and use it in GitHub Desktop.
docker_network
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// api_server.js | |
const express = require('express'); | |
const app = express(); | |
const port = 3000; | |
app.get('/api/data', (req, res) => { | |
res.json({ message: 'Hello from API server!' }); | |
}); | |
app.listen(port, () => { | |
console.log(`API server listening at http://localhost:${port}`); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment