From 48064b4edcc8fa3c263142a09f62ddecf729351a Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 10:40:34 +0200 Subject: [PATCH 1/6] build(backend): transpile and bundle using esbuild --- package.json | 5 +- src/backend/index.ts | 7 +- vite.config.ts | 3 + yarn.lock | 252 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 263 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index d3f9e70..663e46c 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,9 @@ "author": "Serlo Education e.V.", "type": "module", "scripts": { - "build": "tsc && vite build", + "build": "npm-run-all --parallel \"build:*\"", + "build:backend": "esbuild src/backend/index.ts --bundle --platform=node --format=esm --packages=external --outfile=dist/backend/index.js", + "build:frontend": "vite build", "dev": "docker compose up --watch --build", "format": "npm-run-all --sequential --continue-on-error \"format:*\"", "format:eslint": "eslint --fix", @@ -48,6 +50,7 @@ "@types/react-dom": "^18.3.0", "@types/uuid": "^10.0.0", "@vitejs/plugin-react-swc": "^3.7.0", + "esbuild": "^0.24.0", "eslint": "^9.10.0", "eslint-plugin-react": "^7.35.2", "eslint-plugin-react-hooks": "^4.6.2", diff --git a/src/backend/index.ts b/src/backend/index.ts index 3494a8e..02e56f7 100644 --- a/src/backend/index.ts +++ b/src/backend/index.ts @@ -1,13 +1,14 @@ import { Provider as ltijs } from 'ltijs' import 'dotenv/config' -import path from 'path' +import path, { dirname } from 'path' +import { fileURLToPath } from 'url' import jwt from 'jsonwebtoken' import { Pool, createPool } from 'mysql2/promise' import { Database } from './database' import { v4 as uuidv4 } from 'uuid' -// Requires Node.js 20.11 or higher -const __dirname = import.meta.dirname +const __filename = fileURLToPath(import.meta.url) +const __dirname = dirname(__filename) const ltijsKey = readEnvVariable('LTIJS_KEY') const mongodbConnectionUri = readEnvVariable('MONGODB_CONNECTION_URI') diff --git a/vite.config.ts b/vite.config.ts index 861b04b..589bce5 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -3,5 +3,8 @@ import react from '@vitejs/plugin-react-swc' // https://vitejs.dev/config/ export default defineConfig({ + build: { + outDir: './dist/frontend', + }, plugins: [react()], }) diff --git a/yarn.lock b/yarn.lock index bddb4f0..f88fb7a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -28,6 +28,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/aix-ppc64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/aix-ppc64@npm:0.24.0" + conditions: os=aix & cpu=ppc64 + languageName: node + linkType: hard + "@esbuild/android-arm64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/android-arm64@npm:0.21.5" @@ -42,6 +49,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/android-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/android-arm64@npm:0.24.0" + conditions: os=android & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/android-arm@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/android-arm@npm:0.21.5" @@ -56,6 +70,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/android-arm@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/android-arm@npm:0.24.0" + conditions: os=android & cpu=arm + languageName: node + linkType: hard + "@esbuild/android-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/android-x64@npm:0.21.5" @@ -70,6 +91,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/android-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/android-x64@npm:0.24.0" + conditions: os=android & cpu=x64 + languageName: node + linkType: hard + "@esbuild/darwin-arm64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/darwin-arm64@npm:0.21.5" @@ -84,6 +112,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/darwin-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/darwin-arm64@npm:0.24.0" + conditions: os=darwin & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/darwin-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/darwin-x64@npm:0.21.5" @@ -98,6 +133,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/darwin-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/darwin-x64@npm:0.24.0" + conditions: os=darwin & cpu=x64 + languageName: node + linkType: hard + "@esbuild/freebsd-arm64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/freebsd-arm64@npm:0.21.5" @@ -112,6 +154,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/freebsd-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/freebsd-arm64@npm:0.24.0" + conditions: os=freebsd & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/freebsd-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/freebsd-x64@npm:0.21.5" @@ -126,6 +175,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/freebsd-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/freebsd-x64@npm:0.24.0" + conditions: os=freebsd & cpu=x64 + languageName: node + linkType: hard + "@esbuild/linux-arm64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-arm64@npm:0.21.5" @@ -140,6 +196,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-arm64@npm:0.24.0" + conditions: os=linux & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/linux-arm@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-arm@npm:0.21.5" @@ -154,6 +217,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-arm@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-arm@npm:0.24.0" + conditions: os=linux & cpu=arm + languageName: node + linkType: hard + "@esbuild/linux-ia32@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-ia32@npm:0.21.5" @@ -168,6 +238,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-ia32@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-ia32@npm:0.24.0" + conditions: os=linux & cpu=ia32 + languageName: node + linkType: hard + "@esbuild/linux-loong64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-loong64@npm:0.21.5" @@ -182,6 +259,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-loong64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-loong64@npm:0.24.0" + conditions: os=linux & cpu=loong64 + languageName: node + linkType: hard + "@esbuild/linux-mips64el@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-mips64el@npm:0.21.5" @@ -196,6 +280,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-mips64el@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-mips64el@npm:0.24.0" + conditions: os=linux & cpu=mips64el + languageName: node + linkType: hard + "@esbuild/linux-ppc64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-ppc64@npm:0.21.5" @@ -210,6 +301,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-ppc64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-ppc64@npm:0.24.0" + conditions: os=linux & cpu=ppc64 + languageName: node + linkType: hard + "@esbuild/linux-riscv64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-riscv64@npm:0.21.5" @@ -224,6 +322,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-riscv64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-riscv64@npm:0.24.0" + conditions: os=linux & cpu=riscv64 + languageName: node + linkType: hard + "@esbuild/linux-s390x@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-s390x@npm:0.21.5" @@ -238,6 +343,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-s390x@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-s390x@npm:0.24.0" + conditions: os=linux & cpu=s390x + languageName: node + linkType: hard + "@esbuild/linux-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/linux-x64@npm:0.21.5" @@ -252,6 +364,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/linux-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/linux-x64@npm:0.24.0" + conditions: os=linux & cpu=x64 + languageName: node + linkType: hard + "@esbuild/netbsd-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/netbsd-x64@npm:0.21.5" @@ -266,6 +385,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/netbsd-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/netbsd-x64@npm:0.24.0" + conditions: os=netbsd & cpu=x64 + languageName: node + linkType: hard + "@esbuild/openbsd-arm64@npm:0.23.1": version: 0.23.1 resolution: "@esbuild/openbsd-arm64@npm:0.23.1" @@ -273,6 +399,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/openbsd-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/openbsd-arm64@npm:0.24.0" + conditions: os=openbsd & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/openbsd-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/openbsd-x64@npm:0.21.5" @@ -287,6 +420,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/openbsd-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/openbsd-x64@npm:0.24.0" + conditions: os=openbsd & cpu=x64 + languageName: node + linkType: hard + "@esbuild/sunos-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/sunos-x64@npm:0.21.5" @@ -301,6 +441,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/sunos-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/sunos-x64@npm:0.24.0" + conditions: os=sunos & cpu=x64 + languageName: node + linkType: hard + "@esbuild/win32-arm64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/win32-arm64@npm:0.21.5" @@ -315,6 +462,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/win32-arm64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/win32-arm64@npm:0.24.0" + conditions: os=win32 & cpu=arm64 + languageName: node + linkType: hard + "@esbuild/win32-ia32@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/win32-ia32@npm:0.21.5" @@ -329,6 +483,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/win32-ia32@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/win32-ia32@npm:0.24.0" + conditions: os=win32 & cpu=ia32 + languageName: node + linkType: hard + "@esbuild/win32-x64@npm:0.21.5": version: 0.21.5 resolution: "@esbuild/win32-x64@npm:0.21.5" @@ -343,6 +504,13 @@ __metadata: languageName: node linkType: hard +"@esbuild/win32-x64@npm:0.24.0": + version: 0.24.0 + resolution: "@esbuild/win32-x64@npm:0.24.0" + conditions: os=win32 & cpu=x64 + languageName: node + linkType: hard + "@eslint-community/eslint-utils@npm:^4.2.0, @eslint-community/eslint-utils@npm:^4.4.0": version: 4.4.0 resolution: "@eslint-community/eslint-utils@npm:4.4.0" @@ -2145,6 +2313,89 @@ __metadata: languageName: node linkType: hard +"esbuild@npm:^0.24.0": + version: 0.24.0 + resolution: "esbuild@npm:0.24.0" + dependencies: + "@esbuild/aix-ppc64": "npm:0.24.0" + "@esbuild/android-arm": "npm:0.24.0" + "@esbuild/android-arm64": "npm:0.24.0" + "@esbuild/android-x64": "npm:0.24.0" + "@esbuild/darwin-arm64": "npm:0.24.0" + "@esbuild/darwin-x64": "npm:0.24.0" + "@esbuild/freebsd-arm64": "npm:0.24.0" + "@esbuild/freebsd-x64": "npm:0.24.0" + "@esbuild/linux-arm": "npm:0.24.0" + "@esbuild/linux-arm64": "npm:0.24.0" + "@esbuild/linux-ia32": "npm:0.24.0" + "@esbuild/linux-loong64": "npm:0.24.0" + "@esbuild/linux-mips64el": "npm:0.24.0" + "@esbuild/linux-ppc64": "npm:0.24.0" + "@esbuild/linux-riscv64": "npm:0.24.0" + "@esbuild/linux-s390x": "npm:0.24.0" + "@esbuild/linux-x64": "npm:0.24.0" + "@esbuild/netbsd-x64": "npm:0.24.0" + "@esbuild/openbsd-arm64": "npm:0.24.0" + "@esbuild/openbsd-x64": "npm:0.24.0" + "@esbuild/sunos-x64": "npm:0.24.0" + "@esbuild/win32-arm64": "npm:0.24.0" + "@esbuild/win32-ia32": "npm:0.24.0" + "@esbuild/win32-x64": "npm:0.24.0" + dependenciesMeta: + "@esbuild/aix-ppc64": + optional: true + "@esbuild/android-arm": + optional: true + "@esbuild/android-arm64": + optional: true + "@esbuild/android-x64": + optional: true + "@esbuild/darwin-arm64": + optional: true + "@esbuild/darwin-x64": + optional: true + "@esbuild/freebsd-arm64": + optional: true + "@esbuild/freebsd-x64": + optional: true + "@esbuild/linux-arm": + optional: true + "@esbuild/linux-arm64": + optional: true + "@esbuild/linux-ia32": + optional: true + "@esbuild/linux-loong64": + optional: true + "@esbuild/linux-mips64el": + optional: true + "@esbuild/linux-ppc64": + optional: true + "@esbuild/linux-riscv64": + optional: true + "@esbuild/linux-s390x": + optional: true + "@esbuild/linux-x64": + optional: true + "@esbuild/netbsd-x64": + optional: true + "@esbuild/openbsd-arm64": + optional: true + "@esbuild/openbsd-x64": + optional: true + "@esbuild/sunos-x64": + optional: true + "@esbuild/win32-arm64": + optional: true + "@esbuild/win32-ia32": + optional: true + "@esbuild/win32-x64": + optional: true + bin: + esbuild: bin/esbuild + checksum: 10/500f83a1216d6548053007b85c070d8293395db344605b17418c6cf1217e5e8d338fa77fc8af27c23faa121c5528e5b0004d46d3a0cdeb87d48f1b5fa0164bc5 + languageName: node + linkType: hard + "esbuild@npm:~0.23.0": version: 0.23.1 resolution: "esbuild@npm:0.23.1" @@ -4913,6 +5164,7 @@ __metadata: "@types/uuid": "npm:^10.0.0" "@vitejs/plugin-react-swc": "npm:^3.7.0" dotenv: "npm:^16.4.5" + esbuild: "npm:^0.24.0" eslint: "npm:^9.10.0" eslint-plugin-react: "npm:^7.35.2" eslint-plugin-react-hooks: "npm:^4.6.2" From a03dd33906c9fb1ef0558193eb2d5799570ef5eb Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 11:12:47 +0200 Subject: [PATCH 2/6] build(backend): update scripts to start built app using node --- package.json | 3 ++- uberspace/app.ini | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 663e46c..08cb027 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,8 @@ "push-image": "yarn tsx push-image.ts", "push-image:dev": "yarn push-image dev", "push-image:latest": "yarn push-image latest", - "start:dev": "tsx --watch src/backend/index.ts" + "start:dev": "tsx --watch src/backend/index.ts", + "start": "node dist/backend/index.js" }, "dependencies": { "@serlo/editor": "0.14.0", diff --git a/uberspace/app.ini b/uberspace/app.ini index ff880d9..47b7d71 100644 --- a/uberspace/app.ini +++ b/uberspace/app.ini @@ -1,6 +1,6 @@ [program:serlo-app] directory=/home/%(ENV_USER)s/serlo-editor-as-lti-tool -command=yarn start:dev +command=yarn start autostart=true autorestart=true environment=NODE_ENV=production From a2fd8bbef73c9098b0f9fbb2790c682947ad34c4 Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 14:00:19 +0200 Subject: [PATCH 3/6] chore(scripts): update setup_uberspace script comment and log --- scripts/setup_uberspace.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/setup_uberspace.sh b/scripts/setup_uberspace.sh index 09d798d..5d35e6b 100755 --- a/scripts/setup_uberspace.sh +++ b/scripts/setup_uberspace.sh @@ -54,9 +54,9 @@ echo 'Updated environment variables' yarn echo 'Installed dependencies using Yarn' -# Build frontend +# Build frontend and backend yarn build -echo 'Built the frontend app using Yarn' +echo 'Built the frontend and the backend apps using Yarn' # Run the backend as an Uberspace service cp ./uberspace/app.ini ~/etc/services.d/ From 126f9ff611d1b67dee45a38f8e1ae96d3c9a1e54 Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 15:10:12 +0200 Subject: [PATCH 4/6] build(backend): try building as commonjs --- Dockerfile | 17 +++++++++++++++++ Dockerfile.dev | 2 +- docker-compose.yml | 2 +- package.json | 4 ++-- src/backend/index.ts | 8 ++------ 5 files changed, 23 insertions(+), 10 deletions(-) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..6c93fef --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM node:20.17.0 as build +WORKDIR /usr/src/app + +COPY . . +RUN yarn install --immutable + +RUN yarn build + +FROM node:20.17.0 as production + +WORKDIR /usr/src/app + +COPY --from=build /usr/src/app/dist dist + +EXPOSE 3000 + +ENTRYPOINT ["node", "dist/backend/index.cjs"] \ No newline at end of file diff --git a/Dockerfile.dev b/Dockerfile.dev index 352234b..7783fc4 100644 --- a/Dockerfile.dev +++ b/Dockerfile.dev @@ -12,4 +12,4 @@ RUN yarn build EXPOSE 3000 -ENTRYPOINT ["yarn", "start:dev"] \ No newline at end of file +ENTRYPOINT ["yarn", "start"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 6bdc177..8515f3d 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -4,7 +4,7 @@ services: express: build: context: . - dockerfile: Dockerfile.dev + dockerfile: Dockerfile env_file: '.env' depends_on: - mongo diff --git a/package.json b/package.json index 08cb027..2e5ab32 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "type": "module", "scripts": { "build": "npm-run-all --parallel \"build:*\"", - "build:backend": "esbuild src/backend/index.ts --bundle --platform=node --format=esm --packages=external --outfile=dist/backend/index.js", + "build:backend": "esbuild ./src/backend/index.ts --bundle --platform=node --outfile=dist/backend/index.cjs", "build:frontend": "vite build", "dev": "docker compose up --watch --build", "format": "npm-run-all --sequential --continue-on-error \"format:*\"", @@ -23,7 +23,7 @@ "push-image:dev": "yarn push-image dev", "push-image:latest": "yarn push-image latest", "start:dev": "tsx --watch src/backend/index.ts", - "start": "node dist/backend/index.js" + "start": "node dist/backend/index.cjs" }, "dependencies": { "@serlo/editor": "0.14.0", diff --git a/src/backend/index.ts b/src/backend/index.ts index 02e56f7..716ce9f 100644 --- a/src/backend/index.ts +++ b/src/backend/index.ts @@ -1,15 +1,11 @@ import { Provider as ltijs } from 'ltijs' import 'dotenv/config' -import path, { dirname } from 'path' -import { fileURLToPath } from 'url' +import path from 'path' import jwt from 'jsonwebtoken' import { Pool, createPool } from 'mysql2/promise' import { Database } from './database' import { v4 as uuidv4 } from 'uuid' -const __filename = fileURLToPath(import.meta.url) -const __dirname = dirname(__filename) - const ltijsKey = readEnvVariable('LTIJS_KEY') const mongodbConnectionUri = readEnvVariable('MONGODB_CONNECTION_URI') const ltiPlatform = { @@ -88,7 +84,7 @@ ltijs.app.use((_, res, next) => { // Opens Serlo editor ltijs.app.get('/app', async (_, res) => { - return res.sendFile(path.join(__dirname, '../../dist/index.html')) + return res.sendFile(path.join(__dirname, '../../dist/frontend/index.html')) }) // Endpoint to get content From 3cacb8f6063421ec43551be2e32c8c3f4a1224a0 Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 16:20:31 +0200 Subject: [PATCH 5/6] build(backend): leftover path --- src/backend/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/index.ts b/src/backend/index.ts index 716ce9f..3cfcedb 100644 --- a/src/backend/index.ts +++ b/src/backend/index.ts @@ -68,7 +68,7 @@ ltijs.setup( loginUrl: '/lti/login', keysetUrl: '/lti/keys', dynRegRoute: '/lti/register', - staticPath: path.join(__dirname, './../../dist'), // Path to static files + staticPath: path.join(__dirname, './../../dist/frontend'), // Path to static files cookies: { secure: process.env['ENVIRONMENT'] === 'local' ? false : true, // Set secure to true if the testing platform is in a different domain and https is being used sameSite: process.env['ENVIRONMENT'] === 'local' ? '' : 'None', // Set sameSite to 'None' if the testing platform is in a different domain and https is being used From 7a3104c98b3533a4459028d61de0dd618f735ba3 Mon Sep 17 00:00:00 2001 From: Vitomir Budimir Date: Fri, 27 Sep 2024 16:32:32 +0200 Subject: [PATCH 6/6] build(backend): revert to Dockerfile.dev in docker-compose --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index 8515f3d..6bdc177 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -4,7 +4,7 @@ services: express: build: context: . - dockerfile: Dockerfile + dockerfile: Dockerfile.dev env_file: '.env' depends_on: - mongo