From 1d7e11e11f8b477d00479b0c926abb336bcab245 Mon Sep 17 00:00:00 2001 From: NPM Update Bot Date: Mon, 26 Feb 2024 00:12:23 +0000 Subject: [PATCH 01/10] npm: package updates --- src/package-lock.json | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/package-lock.json b/src/package-lock.json index 259fe87..836e56e 100644 --- a/src/package-lock.json +++ b/src/package-lock.json @@ -5078,10 +5078,13 @@ "dev": true }, "node_modules/yaml": { - "version": "2.3.4", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.3.4.tgz", - "integrity": "sha512-8aAvwVUSHpfEqTQ4w/KMlf3HcRdt50E5ODIQJBw1fQ5RL34xabzxtUlzTXVqc4rkZsPbvrXKWnABCD7kWSmocA==", + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.4.0.tgz", + "integrity": "sha512-j9iR8g+/t0lArF4V6NE/QCfT+CO7iLqrXAHZbJdo+LfjqP1vR8Fg5bSiaq6Q2lOD1AUEVrEVIgABvBFYojJVYQ==", "dev": true, + "bin": { + "yaml": "bin.mjs" + }, "engines": { "node": ">= 14" } From f963e7a4d1e5e6e55e62b21ac469ab1c0537678f Mon Sep 17 00:00:00 2001 From: NPM Update Bot Date: Wed, 28 Feb 2024 00:11:32 +0000 Subject: [PATCH 02/10] npm: package updates --- src/package-lock.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/package-lock.json b/src/package-lock.json index 836e56e..2c23b2e 100644 --- a/src/package-lock.json +++ b/src/package-lock.json @@ -1681,9 +1681,9 @@ } }, "node_modules/eslint-module-utils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.0.tgz", - "integrity": "sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==", + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.1.tgz", + "integrity": "sha512-rXDXR3h7cs7dy9RNpUlQf80nX31XWJEyGq1tRMo+6GsO5VmTe4UTwtmonAD4ZkAsrfMVDA2wlGJ3790Ys+D49Q==", "dev": true, "dependencies": { "debug": "^3.2.7" From c733ef410df43f14d3a1bb8d9c6efb9f0a2c85c8 Mon Sep 17 00:00:00 2001 From: NPM Update Bot Date: Thu, 29 Feb 2024 00:11:47 +0000 Subject: [PATCH 03/10] npm: package updates --- src/package-lock.json | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/package-lock.json b/src/package-lock.json index 2c23b2e..45fceda 100644 --- a/src/package-lock.json +++ b/src/package-lock.json @@ -1425,18 +1425,18 @@ } }, "node_modules/es-abstract": { - "version": "1.22.4", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.4.tgz", - "integrity": "sha512-vZYJlk2u6qHYxBOTjAeg7qUxHdNfih64Uu2J8QqWgXZ2cri0ZpJAkzDUK/q593+mvKwlxyaxr6F1Q+3LKoQRgg==", + "version": "1.22.5", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.5.tgz", + "integrity": "sha512-oW69R+4q2wG+Hc3KZePPZxOiisRIqfKBVo/HLx94QcJeWGU/8sZhCvc829rd1kS366vlJbzBfXf9yWwf0+Ko7w==", "dev": true, "dependencies": { "array-buffer-byte-length": "^1.0.1", "arraybuffer.prototype.slice": "^1.0.3", - "available-typed-arrays": "^1.0.6", + "available-typed-arrays": "^1.0.7", "call-bind": "^1.0.7", "es-define-property": "^1.0.0", "es-errors": "^1.3.0", - "es-set-tostringtag": "^2.0.2", + "es-set-tostringtag": "^2.0.3", "es-to-primitive": "^1.2.1", "function.prototype.name": "^1.1.6", "get-intrinsic": "^1.2.4", @@ -1444,15 +1444,15 @@ "globalthis": "^1.0.3", "gopd": "^1.0.1", "has-property-descriptors": "^1.0.2", - "has-proto": "^1.0.1", + "has-proto": "^1.0.3", "has-symbols": "^1.0.3", "hasown": "^2.0.1", "internal-slot": "^1.0.7", "is-array-buffer": "^3.0.4", "is-callable": "^1.2.7", - "is-negative-zero": "^2.0.2", + "is-negative-zero": "^2.0.3", "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.2", + "is-shared-array-buffer": "^1.0.3", "is-string": "^1.0.7", "is-typed-array": "^1.1.13", "is-weakref": "^1.0.2", @@ -1465,10 +1465,10 @@ "string.prototype.trim": "^1.2.8", "string.prototype.trimend": "^1.0.7", "string.prototype.trimstart": "^1.0.7", - "typed-array-buffer": "^1.0.1", - "typed-array-byte-length": "^1.0.0", - "typed-array-byte-offset": "^1.0.0", - "typed-array-length": "^1.0.4", + "typed-array-buffer": "^1.0.2", + "typed-array-byte-length": "^1.0.1", + "typed-array-byte-offset": "^1.0.2", + "typed-array-length": "^1.0.5", "unbox-primitive": "^1.0.2", "which-typed-array": "^1.1.14" }, From 9ca88e18af9430ed26ab23c19639d35245ea9356 Mon Sep 17 00:00:00 2001 From: NPM Update Bot Date: Fri, 1 Mar 2024 00:13:45 +0000 Subject: [PATCH 04/10] npm: package updates --- src/package-lock.json | 40 ++++++++++++++++++++-------------------- src/package.json | 2 +- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/src/package-lock.json b/src/package-lock.json index 45fceda..d89971f 100644 --- a/src/package-lock.json +++ b/src/package-lock.json @@ -11,7 +11,7 @@ "dependencies": { "bcryptjs": "^2.4.3", "debug": "^4.3.4", - "express": "^4.18.2", + "express": "^4.18.3", "express-session": "^1.18.0", "qrcode": "^1.5.3", "uuid": "^9.0.1" @@ -404,9 +404,9 @@ } }, "node_modules/@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, "engines": { "node": ">=6.0.0" @@ -991,12 +991,12 @@ } }, "node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "dependencies": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -1004,7 +1004,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -2107,13 +2107,13 @@ } }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.18.3", + "resolved": "https://registry.npmjs.org/express/-/express-4.18.3.tgz", + "integrity": "sha512-6VyCijWQ+9O7WuVMTRBTl+cjNNIzD5cY5mQ1WM8r/LEkI2u8EYpOotESNwzNlyCn3g+dmjKYI6BmNneSr/FSRw==", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.5.0", @@ -3986,9 +3986,9 @@ } }, "node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "dependencies": { "bytes": "3.1.2", "http-errors": "2.0.0", @@ -4341,11 +4341,11 @@ } }, "node_modules/side-channel": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.5.tgz", - "integrity": "sha512-QcgiIWV4WV7qWExbN5llt6frQB/lBven9pqliLXfGPB+K9ZYXxDozp0wLkHS24kWCm+6YXH/f0HhnObZnZOBnQ==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", "dependencies": { - "call-bind": "^1.0.6", + "call-bind": "^1.0.7", "es-errors": "^1.3.0", "get-intrinsic": "^1.2.4", "object-inspect": "^1.13.1" diff --git a/src/package.json b/src/package.json index 68056ac..14cf518 100644 --- a/src/package.json +++ b/src/package.json @@ -15,7 +15,7 @@ "dependencies": { "bcryptjs": "^2.4.3", "debug": "^4.3.4", - "express": "^4.18.2", + "express": "^4.18.3", "express-session": "^1.18.0", "qrcode": "^1.5.3", "uuid": "^9.0.1" From 58435fe972b33fef42e4ffab2e9d7803929b6280 Mon Sep 17 00:00:00 2001 From: Chanchai Date: Wed, 28 Feb 2024 10:46:05 +0700 Subject: [PATCH 05/10] Added Thai language --- docker-compose.yml | 2 +- src/www/js/i18n.js | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index 2c529a6..81395ac 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,7 +6,7 @@ services: wg-easy: environment: # Change Language: - # (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, pt, chs, cht) + # (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, pt, chs, cht, th) - LANG=de # ⚠️ Required: # Change this to your host's public address diff --git a/src/www/js/i18n.js b/src/www/js/i18n.js index 04e1b49..bbf7500 100644 --- a/src/www/js/i18n.js +++ b/src/www/js/i18n.js @@ -461,4 +461,31 @@ const messages = { // eslint-disable-line no-unused-vars madeBy: '由', donate: '捐贈', }, + th: { + name: 'ชื่อ', + password: 'รหัสผ่าน', + signIn: 'ลงชื่อเข้าใช้', + logout: 'ออกจากระบบ', + updateAvailable: 'มีอัปเดตพร้อมใช้งาน!', + update: 'อัปเดต', + clients: 'ไคลแอนด์', + new: 'ใหม่', + deleteClient: 'ลบ ไคลแอนด์', + deleteDialog1: 'คุณแน่ใจหรือไม่ว่าต้องการลบ', + deleteDialog2: 'การกระทำนี้;ไม่สามารถยกเลิกได้', + cancel: 'ยกเลิก', + create: 'สร้าง', + createdOn: 'สร้างเมื่อ ', + lastSeen: 'เห็นครั้งสุดท้ายเมื่อ ', + totalDownload: 'ดาวน์โหลดทั้งหมด: ', + totalUpload: 'อัพโหลดทั้งหมด: ', + newClient: 'ไคลแอนด์ ใหม่', + disableClient: 'ปิดการใช้งาน ไคลแอนด์', + enableClient: 'เปิดการใช้งาน ไคลแอนด์', + noClients: 'ยังไม่มี ไคลแอนด์ เลย', + showQR: 'แสดงรหัส QR', + downloadConfig: 'ดาวน์โหลดการตั้งค่า', + madeBy: 'สร้างโดย', + donate: 'บริจาค', + }, }; From 811ac30fd3e9c0b02a705c6b76e727c342d0b77d Mon Sep 17 00:00:00 2001 From: Chanchai Date: Wed, 28 Feb 2024 11:06:57 +0700 Subject: [PATCH 06/10] update Thai language --- src/www/js/i18n.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/www/js/i18n.js b/src/www/js/i18n.js index bbf7500..59e8214 100644 --- a/src/www/js/i18n.js +++ b/src/www/js/i18n.js @@ -468,9 +468,9 @@ const messages = { // eslint-disable-line no-unused-vars logout: 'ออกจากระบบ', updateAvailable: 'มีอัปเดตพร้อมใช้งาน!', update: 'อัปเดต', - clients: 'ไคลแอนด์', + clients: 'Clients', new: 'ใหม่', - deleteClient: 'ลบ ไคลแอนด์', + deleteClient: 'ลบ Client', deleteDialog1: 'คุณแน่ใจหรือไม่ว่าต้องการลบ', deleteDialog2: 'การกระทำนี้;ไม่สามารถยกเลิกได้', cancel: 'ยกเลิก', @@ -479,10 +479,10 @@ const messages = { // eslint-disable-line no-unused-vars lastSeen: 'เห็นครั้งสุดท้ายเมื่อ ', totalDownload: 'ดาวน์โหลดทั้งหมด: ', totalUpload: 'อัพโหลดทั้งหมด: ', - newClient: 'ไคลแอนด์ ใหม่', - disableClient: 'ปิดการใช้งาน ไคลแอนด์', - enableClient: 'เปิดการใช้งาน ไคลแอนด์', - noClients: 'ยังไม่มี ไคลแอนด์ เลย', + newClient: 'Client ใหม่', + disableClient: 'ปิดการใช้งาน Client', + enableClient: 'เปิดการใช้งาน Client', + noClients: 'ยังไม่มี Clients เลย', showQR: 'แสดงรหัส QR', downloadConfig: 'ดาวน์โหลดการตั้งค่า', madeBy: 'สร้างโดย', From d3864bb065681a17987116eb1a6917e4c3fe009e Mon Sep 17 00:00:00 2001 From: Chanchai Date: Thu, 29 Feb 2024 15:36:45 +0700 Subject: [PATCH 07/10] update readme --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 61eda10..fd15709 100644 --- a/README.md +++ b/README.md @@ -97,7 +97,7 @@ These options can be configured by setting environment variables using `-e KEY=" | `WG_POST_UP` | `...` | `iptables ...` | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L20) for the default value. | | `WG_PRE_DOWN` | `...` | - | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L27) for the default value. | | `WG_POST_DOWN` | `...` | `iptables ...` | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L28) for the default value. | -| `LANG` | `en` | `de` | Web UI language (Supports: en, ru, tr, no, pl, fr, de, ca, es, vi, nl, is, chs, cht,). | +| `LANG` | `en` | `de` | Web UI language (Supports: en, ru, tr, no, pl, fr, de, ca, es, vi, nl, is, chs, cht, th,). | > If you change `WG_PORT`, make sure to also change the exposed port. From a6767cafb204464940233704973bb38264e45261 Mon Sep 17 00:00:00 2001 From: davide-acanfora Date: Mon, 26 Feb 2024 10:08:41 +0100 Subject: [PATCH 08/10] Added Italian language. Updated supported languages list --- README.md | 2 +- docker-compose.yml | 2 +- src/www/js/i18n.js | 27 +++++++++++++++++++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 61eda10..53eef44 100644 --- a/README.md +++ b/README.md @@ -97,7 +97,7 @@ These options can be configured by setting environment variables using `-e KEY=" | `WG_POST_UP` | `...` | `iptables ...` | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L20) for the default value. | | `WG_PRE_DOWN` | `...` | - | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L27) for the default value. | | `WG_POST_DOWN` | `...` | `iptables ...` | See [config.js](https://github.com/wg-easy/wg-easy/blob/master/src/config.js#L28) for the default value. | -| `LANG` | `en` | `de` | Web UI language (Supports: en, ru, tr, no, pl, fr, de, ca, es, vi, nl, is, chs, cht,). | +| `LANG` | `en` | `de` | Web UI language (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, ko, vi, nl, is, pt, chs, cht, it). | > If you change `WG_PORT`, make sure to also change the exposed port. diff --git a/docker-compose.yml b/docker-compose.yml index 2c529a6..57f829e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,7 +6,7 @@ services: wg-easy: environment: # Change Language: - # (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, pt, chs, cht) + # (Supports: en, ua, ru, tr, no, pl, fr, de, ca, es, ko, vi, nl, is, pt, chs, cht, it) - LANG=de # ⚠️ Required: # Change this to your host's public address diff --git a/src/www/js/i18n.js b/src/www/js/i18n.js index 04e1b49..c9a3151 100644 --- a/src/www/js/i18n.js +++ b/src/www/js/i18n.js @@ -461,4 +461,31 @@ const messages = { // eslint-disable-line no-unused-vars madeBy: '由', donate: '捐贈', }, + it: { + name: 'Nome', + password: 'Password', + signIn: 'Accedi', + logout: 'Esci', + updateAvailable: 'È disponibile un aggiornamento!', + update: 'Aggiorna', + clients: 'Client', + new: 'Nuovo', + deleteClient: 'Elimina Client', + deleteDialog1: 'Sei sicuro di voler eliminare', + deleteDialog2: 'Questa azione non può essere annullata.', + cancel: 'Annulla', + create: 'Crea', + createdOn: 'Creato il ', + lastSeen: 'Visto l\'ultima volta il ', + totalDownload: 'Totale Download: ', + totalUpload: 'Totale Upload: ', + newClient: 'Nuovo Client', + disableClient: 'Disabilita Client', + enableClient: 'Abilita Client', + noClients: 'Non ci sono ancora client.', + showQR: 'Mostra codice QR', + downloadConfig: 'Scarica configurazione', + madeBy: 'Realizzato da', + donate: 'Donazione', + }, }; From 075c13bfc22d6f899b157871431d5bdcef1168c8 Mon Sep 17 00:00:00 2001 From: NPM Update Bot Date: Fri, 1 Mar 2024 13:13:09 +0000 Subject: [PATCH 09/10] npm: package updates --- src/package-lock.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/package-lock.json b/src/package-lock.json index d89971f..0e9943f 100644 --- a/src/package-lock.json +++ b/src/package-lock.json @@ -381,14 +381,14 @@ } }, "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.4", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.4.tgz", - "integrity": "sha512-Oud2QPM5dHviZNn4y/WhhYKSXksv+1xLEIsNrAbGcFzUN3ubqWRFT5gwPchNc5NuzILOU4tPBDTZ4VwhL8Y7cw==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "dependencies": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" @@ -419,9 +419,9 @@ "dev": true }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.23", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.23.tgz", - "integrity": "sha512-9/4foRoUKp8s96tSkh8DlAAc5A0Ty8vLXld+l9gjKKY6ckwI8G15f0hskGmuLZu78ZlGa1vtsfOa+lnB4vG6Jg==", + "version": "0.3.24", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.24.tgz", + "integrity": "sha512-+VaWXDa6+l6MhflBvVXjIEAzb59nQ2JUK3bwRp2zRpPtU+8TFRy9Gg/5oIcNlkEL5PGlBFGfemUVvIgLnTzq7Q==", "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", From 50add72345edff9dd381d30374376aa886a42944 Mon Sep 17 00:00:00 2001 From: davide-acanfora Date: Thu, 29 Feb 2024 21:58:45 +0100 Subject: [PATCH 10/10] Reduce docker image size --- Dockerfile | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index baf9941..4e410b8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,7 +6,8 @@ FROM docker.io/library/node:18-alpine AS build_node_modules # Copy Web UI COPY src/ /app/ WORKDIR /app -RUN npm ci --omit=dev +RUN npm ci --omit=dev &&\ + mv node_modules /node_modules # Copy build result to a new image. # This saves a lot of disk space. @@ -20,13 +21,15 @@ COPY --from=build_node_modules /app /app # Also, some node_modules might be native, and # the architecture & OS of your development machine might differ # than what runs inside of docker. -RUN mv /app/node_modules /node_modules +COPY --from=build_node_modules /node_modules /node_modules -# Enable this to run `npm run serve` -RUN npm i -g nodemon - -# Workaround CVE-2023-42282 -RUN npm uninstall -g ip +RUN \ + # Enable this to run `npm run serve` + npm i -g nodemon &&\ + # Workaround CVE-2023-42282 + npm uninstall -g ip &&\ + # Delete unnecessary files + npm cache clean --force && rm -rf ~/.npm # Install Linux packages RUN apk add --no-cache \