Spaces:
Build error
Build error
server js
Browse files- Dockerfile +4 -2
- mocos.js +7 -1
Dockerfile
CHANGED
|
@@ -31,8 +31,10 @@ RUN ls
|
|
| 31 |
|
| 32 |
RUN node -v
|
| 33 |
RUN npm -v
|
| 34 |
-
|
| 35 |
-
|
|
|
|
|
|
|
| 36 |
# RUN cd /dist/. /var/etc/html
|
| 37 |
#USER root
|
| 38 |
#RUN cat /etc/passwd
|
|
|
|
| 31 |
|
| 32 |
RUN node -v
|
| 33 |
RUN npm -v
|
| 34 |
+
|
| 35 |
+
RUN npm install
|
| 36 |
+
RUN npm build
|
| 37 |
+
|
| 38 |
# RUN cd /dist/. /var/etc/html
|
| 39 |
#USER root
|
| 40 |
#RUN cat /etc/passwd
|
mocos.js
CHANGED
|
@@ -1 +1,7 @@
|
|
| 1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
const http = require("http");
|
| 2 |
+
|
| 3 |
+
const server = http.createServer(requestListener);
|
| 4 |
+
|
| 5 |
+
server.listen(port, host, () => {
|
| 6 |
+
console.log(`Server is running on http://${host}:${port}`);
|
| 7 |
+
});
|