Skip to content
This repository has been archived by the owner on Jun 22, 2023. It is now read-only.

Commit

Permalink
feat(project): update build and start scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristiaanScheermeijer committed Mar 11, 2020
1 parent 2f110d4 commit 26399c4
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 6 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*
.idea/*
/dist
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ WORKDIR /app
COPY package.json .
COPY package-lock.json .
RUN npm install
RUN npm build
COPY . .

EXPOSE 80

CMD ["npm", "start"]
CMD ["npm", "start:prod"]
48 changes: 45 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,15 @@
"jest": "^24.9.0",
"lint-staged": "9.5.*",
"node-fetch": "2.3.*",
"nodemon": "^1.19.1"
"nodemon": "^1.19.1",
"rimraf": "^3.0.2"
},
"scripts": {
"build": "rimraf ./dist && babel ./src --out-dir ./dist --copy-files",
"build:debug": "rimraf ./dist && babel ./src --out-dir ./dist --copy-files --source-maps",
"lint": "eslint src tests",
"start": "nodemon --exec babel-node --watch src src/index.js",
"start": "babel-node --watch src src/index.js",
"start:prod": "nodemon --exec node dist/index.js",
"test:functional": "CI=true jest tests/helpers.js tests/functional",
"version": "conventional-changelog -i CHANGELOG.md -s && git add -A CHANGELOG.md"
},
Expand Down

0 comments on commit 26399c4

Please sign in to comment.