Skip to content

Commit

Permalink
Merge branch 'release/1.0.0' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
iagomachadocs committed Oct 8, 2021
2 parents 3ab2348 + 54d822b commit a4c3317
Show file tree
Hide file tree
Showing 69 changed files with 5,836 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules
.git
.vscode
sysbkp
12 changes: 12 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = false
insert_final_newline = false
3 changes: 3 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
MONGO_DB_USERNAME=
MONGO_DB_PASSWORD=
MONGO_DB_ADDRESS=
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/*.js
node_modules
dist
73 changes: 73 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"env": {
"es2020": true,
"node": true
},
"extends": [
"standard",
"prettier",
"plugin:prettier/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 12,
"sourceType": "module"
},
"plugins": [
"@typescript-eslint",
"eslint-plugin-import-helpers",
"prettier"
],
"rules": {
"camelcase": [2, {"properties": "always"}],
"import/no-unresolved": "error",
"@typescript-eslint/naming-convention": [
"error",
{
"selector": "interface",
"format": ["PascalCase"],
"custom": {
"regex": "^I[A-Z]",
"match": true
}
}
],
"class-methods-use-this": "off",
"import/prefer-default-export": "off",
"no-shadow": "off",
"no-console": "off",
"no-useless-constructor": "off",
"no-empty-function": "off",
"lines-between-class-members": "off",
"import/extensions": [
"error",
"ignorePackages",
{
"ts": "never"
}
],
"import-helpers/order-imports": [
"warn",
{
// example configuration
"newlinesBetween": "always",
"groups": ["module", "/^@shared/", ["parent", "sibling", "index"]],
"alphabetize": { "order": "asc", "ignoreCase": true }
}
],
"import/no-extraneous-dependencies": [
"error",
{"devDependencies": ["/*.test.ts", "/.test.tsx", "**/.ts"]}
],
"space-before-blocks": ["error", "always"],
"prettier/prettier": ["error",{
"semi":false,
"singleQuote": true
}]
},
"settings": {
"import/resolver": {
"typescript": {}
}
}
}
19 changes: 19 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
FROM node AS build
WORKDIR /usr/app
COPY package.json ./
COPY tsconfig.json ./
COPY src ./src
RUN npm install
RUN npm run build

FROM node
WORKDIR /usr/app
COPY package.json ./
RUN npm install --production
COPY --from=build /usr/app/dist ./dist
COPY .env.example ./
COPY .env ./
RUN npm install pm2 -g
EXPOSE 5000
CMD ["pm2-runtime", "dist/server.js"]

13 changes: 13 additions & 0 deletions Dockerfile.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM node:latest

WORKDIR /usr/app

COPY package.json ./

RUN npm install

COPY . .

EXPOSE 5000

CMD ["npm","run","dev"]
Loading

0 comments on commit a4c3317

Please sign in to comment.