Skip to content

Commit

Permalink
adiciona arquivos de configuracao docker
Browse files Browse the repository at this point in the history
  • Loading branch information
HenriqueAmorim20 committed Nov 7, 2023
1 parent 490c6ed commit 7f7db7b
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM node:18.17.0-alpine as BUILD_NODE_MODULES

RUN apk update && apk add curl bash make && rm -rf /var/cache/apk/*

WORKDIR /home/node/app

RUN npm i -g --unsafe-perm --allow-root -g expo-cli@6.3.10

COPY package*.json ./

RUN npm ci --legacy-peer-deps


FROM node:18.17.0-alpine

ENV NODE_ENV=production

WORKDIR /app

COPY --chown=node:node ./ /app
COPY --chown=node:node --from=BUILD_NODE_MODULES /home/node/app/node_modules /app/node_modules

USER node

EXPOSE 8081

ENTRYPOINT ["npm"]
CMD ["start"]
12 changes: 12 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
version: '3.7'
services:
gerocuidado-usuario-front:
build:
context: .
dockerfile: Dockerfile
container_name: gerocuidado-usuario-front
ports:
- '8081:8081'
volumes:
- ./:/app
- /app/node_modules

0 comments on commit 7f7db7b

Please sign in to comment.