Skip to content

Commit 5d3c05c

Browse files
committed
Remove dotenv
1 parent 00abd18 commit 5d3c05c

File tree

6 files changed

+8
-17
lines changed

6 files changed

+8
-17
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ USER ackee
4040
# Run healthcheck against MongoDB, server and API.
4141
# Wait a bit before start to ensure the build is done.
4242

43-
HEALTHCHECK --interval=1m --timeout=45s --start-period=45s CMD [ "/srv/app/src/healthcheck.js" ]
43+
HEALTHCHECK --interval=1m --timeout=45s --start-period=45s CMD [ "npm", "run", "healthcheck" ]
4444

4545
# Start Ackee
4646

build.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
#!/usr/bin/env node
2-
import 'dotenv/config'
3-
41
import { build, index, scripts, styles, tracker } from './src/ui/index.js'
52
import config from './src/utils/config.js'
63
import * as customTracker from './src/utils/customTracker.js'

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,15 @@
2121
"type": "module",
2222
"main": "src/index.js",
2323
"scripts": {
24-
"build": "node build.js",
24+
"build": "node --env-file-if-exists=.env build.js",
2525
"build:pre": "BUILD_ENV=pre npm run build",
2626
"dev": "NODE_ENV=development nodemon",
2727
"eslint": "eslint \"**/*.js\"",
2828
"format": "npm run eslint -- --fix && npm run prettier -- --write",
29+
"healthcheck": "node --env-file-if-exists=.env src/healthcheck.js",
2930
"lint": "npm run eslint && npm run prettier -- --check",
3031
"prettier": "prettier \"**/*.{js,json,md,yml}\"",
31-
"server": "node src/index.js",
32+
"server": "node --env-file-if-exists=.env src/index.js",
3233
"start": "npm run build && npm run server",
3334
"test": "npm run lint && ava"
3435
},
@@ -57,7 +58,6 @@
5758
"date-fns": "^4.1.0",
5859
"date-fns-tz": "^3.2.0",
5960
"debounce-promise": "^3.1.2",
60-
"dotenv": "^16.6.1",
6161
"express": "^4.21.2",
6262
"graphql": "^16.12.0",
6363
"graphql-scalars": "^1.25.0",

src/healthcheck.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
#!/usr/bin/env node
2-
import 'dotenv/config'
3-
41
import config from './utils/config.js'
52
import connect from './utils/connect.js'
63
import signale from './utils/signale.js'

src/index.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
#!/usr/bin/env node
2-
import 'dotenv/config'
3-
41
import server from './server.js'
52
import config from './utils/config.js'
63
import connect from './utils/connect.js'

0 commit comments

Comments
 (0)