Skip to content

Commit 5dc4703

Browse files
author
Luiz Filipy
committed
😊 Adicionado NodeJS 😊
1 parent 90c8838 commit 5dc4703

File tree

6 files changed

+431
-4
lines changed

6 files changed

+431
-4
lines changed

NodeJS/.dockerignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules

NodeJS/Dockerfile

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
FROM node:latest
2+
3+
RUN mkdir -p /home/node/app/node_modules && chown -R node:node /home/node/app
4+
5+
WORKDIR /home/node/app
6+
7+
COPY package*.json ./
8+
9+
RUN npm install
10+
11+
COPY . .
12+
13+
CMD [ "npm", "start" ]

NodeJS/app.js

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
const express = require('express')
2+
3+
const app = express()
4+
5+
app.use('/', (req, res) => {
6+
res.sendStatus(200)
7+
})
8+
9+
.listen(process.env.PORT || 3000, () => {
10+
console.log('•ᴗ• - servidor em execução');
11+
});

0 commit comments

Comments
 (0)