-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from Lissone/feature/docker
Feature - Added Docker
- Loading branch information
Showing
7 changed files
with
114 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# docker | ||
.dockerignore | ||
Dockerfile* | ||
docker-compose* | ||
|
||
# git | ||
.git | ||
.gitignore | ||
|
||
# generated | ||
node_modules | ||
build | ||
dist | ||
coverage | ||
|
||
# other | ||
*.log | ||
.husky | ||
.vscode | ||
.env.example | ||
CHANGELOG.md | ||
README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
FROM node:18-alpine | ||
|
||
ENV TZ=America/Sao_Paulo | ||
ENV NODE_OPTIONS=--max-old-space-size=4096 | ||
|
||
WORKDIR /app | ||
|
||
COPY package*.json ./ | ||
|
||
# --production=false para instalar tudo | ||
RUN npm install --legacy-peer-deps --production=false | ||
|
||
COPY . . | ||
|
||
RUN npm run --silent build | ||
|
||
ARG APP_PORT=5000 | ||
ENV APP_PORT $APP_PORT | ||
EXPOSE $APP_PORT | ||
|
||
CMD npm run --silent start | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
version: '3' | ||
|
||
services: | ||
sqlserver: | ||
image: mcr.microsoft.com/mssql/server:2022-latest | ||
ports: | ||
- '1433:1433' | ||
environment: | ||
MSSQL_SA_PASSWORD: Dev1234! | ||
ACCEPT_EULA: Y | ||
MSSQL_PID: Developer | ||
|
||
redis: | ||
image: 'redis:alpine' | ||
ports: | ||
- '6379:6379' | ||
|
||
api: | ||
container_name: ${APP_NAME} | ||
image: ${APP_NAME}:${APP_VERSION} | ||
build: | ||
context: . | ||
args: | ||
APP_PORT: ${APP_PORT} | ||
restart: always | ||
ports: | ||
- ${APP_PORT}:${APP_PORT} | ||
depends_on: | ||
- redis | ||
- sqlserver |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters