Spaces:
Build error
Build error
Create index.js
Browse files
index.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
const express = require('express');
|
| 2 |
+
const app = express();
|
| 3 |
+
// Hugging Face strictly expects Port 7860
|
| 4 |
+
const port = 7860;
|
| 5 |
+
|
| 6 |
+
app.get('/', (req, res) => {
|
| 7 |
+
res.send('Hello Treyvon! Your Docker app is running live on Hugging Face.');
|
| 8 |
+
});
|
| 9 |
+
|
| 10 |
+
app.listen(port, () => {
|
| 11 |
+
console.log(`App listening at http://localhost:${port}`);
|
| 12 |
+
});
|