Last active
June 28, 2020 17:20
-
-
Save luiszugasti/20fe3558a220f5640dbb8b67192c575c to your computer and use it in GitHub Desktop.
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
const express = require('express'); | |
const path = require('path'); | |
const app = express(); | |
const port = 3000; | |
const os = require('os'); | |
// D:\\Videos\\ | |
const dir = process.env.VIDEO; | |
// SERVE RIGHT TO YOUR DOOR | |
app.use(express.static(dir)); | |
app.get('/', (res, req) => res.send("Server is up and running.")); | |
app.listen(port, () => console.log(`Example application listening at http://localhost:${port}`)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment