Adding a Yarn command to profile
authorDavid Négrier <d.negrier@thecodingmachine.com>
Wed, 3 Jun 2020 07:18:49 +0000 (09:18 +0200)
committerDavid Négrier <d.negrier@thecodingmachine.com>
Wed, 3 Jun 2020 07:18:49 +0000 (09:18 +0200)
back/package.json
docker-compose.yaml

index e75b21465a577f8a78772a8560416035409bb54e..ca649707a42d67d1974469de93f3b0912deb38dc 100644 (file)
@@ -7,6 +7,7 @@
     "tsc": "tsc",
     "dev": "ts-node-dev --respawn --transpileOnly ./server.ts",
     "prod": "tsc && node ./dist/server.js",
+    "profile": "tsc && node --prof ./dist/server.js",
     "test": "ts-node node_modules/jasmine/bin/jasmine --config=jasmine.json",
     "lint": "node_modules/.bin/eslint src/ . --ext .ts",
     "fix": "node_modules/.bin/eslint --fix src/ . --ext .ts"
index ca2197a836ec6bb4dfe44520d2c3a62fc5bd3b9c..e6d3607a0149c6ab64167a168ae327c332af1ef1 100644 (file)
@@ -31,6 +31,7 @@ services:
   back:
     image: thecodingmachine/nodejs:12
     command: yarn dev
+    #command: yarn run profile
     environment:
       STARTUP_COMMAND_1: yarn install
       SECRET_KEY: yourSecretKey