Skip to content

Commit

Permalink
Tarefa prática rcaa#2 - Docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Igordcs committed Jul 13, 2024
1 parent 1274786 commit a0e4e1a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "Toy example of microservice",
"main": "",
"scripts": {
"start": "run-p start-frontend start-controller start-shipping start-inventory",
"start": "run-p start-frontend start-controller start-inventory",
"start-controller": "nodemon services/controller/index.js",
"start-shipping": "nodemon services/shipping/index.js",
"start-inventory": "nodemon services/inventory/index.js",
Expand Down
14 changes: 14 additions & 0 deletions shipping.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Imagem base derivada do Node
FROM node

# Diretório de trabalho
WORKDIR /app

# Comando para copiar os arquivos para a pasta /app da imagem
COPY . /app

# Comando para instalar as dependências
RUN npm install

# Comando para inicializar (executar) a aplicação
CMD ["node", "/app/services/shipping/index.js"]

0 comments on commit a0e4e1a

Please sign in to comment.