shasee commited on
Commit
32db65b
·
verified ·
1 Parent(s): c7e5f09

Update server.js

Browse files
Files changed (1) hide show
  1. server.js +8 -24
server.js CHANGED
@@ -1,24 +1,8 @@
1
- import os
2
- import subprocess
3
-
4
- print("=" * 80)
5
- print("NODE BINARY")
6
- subprocess.run("which node", shell=True)
7
-
8
- print("=" * 80)
9
- print("GRADIO PACKAGE")
10
- subprocess.run("python - <<'PY'\nimport gradio, os\nprint(gradio.__file__)\nPY", shell=True)
11
-
12
- print("=" * 80)
13
- print("NODE FILES")
14
- subprocess.run(r"find /usr/local/lib/python3.10/site-packages/gradio -type f | grep -Ei 'node|server|ssr|js|mjs|ts|package.json'", shell=True)
15
-
16
- print("=" * 80)
17
- print("PACKAGE.JSON")
18
- subprocess.run(r"find /usr/local/lib/python3.10/site-packages/gradio -name package.json", shell=True)
19
-
20
- print("=" * 80)
21
- print("FRONTEND")
22
- subprocess.run(r"find /usr/local/lib/python3.10/site-packages/gradio -type d | grep frontend", shell=True)
23
-
24
- print("=" * 80)
 
1
+ const http = require('http');
2
+ const server = http.createServer((req, res) => {
3
+ res.writeHead(200, {'Content-Type': 'text/html'});
4
+ res.end('<h1>OCHF Node.js Server</h1><p>Running on port 8888!</p>');
5
+ });
6
+ server.listen(8888, '0.0.0.0', () => {
7
+ console.log('Node.js server running on port 8888');
8
+ });