From ed0acd8e584b6ed7e7a968801d0cba2ab7330452 Mon Sep 17 00:00:00 2001 From: Brian Gough Date: Wed, 19 Apr 2023 10:01:25 +0100 Subject: [PATCH] Merge pull request #12658 from overleaf/bg-node-18-upgrade Upgrade to node 18 GitOrigin-RevId: 1b25d20a8987950a72a7bf966a825794de4ad960 --- libraries/access-token-encryptor/.nvmrc | 2 +- .../access-token-encryptor/buildscript.txt | 2 +- libraries/logger/.nvmrc | 2 +- libraries/logger/buildscript.txt | 2 +- libraries/metrics/.nvmrc | 2 +- libraries/metrics/buildscript.txt | 2 +- libraries/o-error/.nvmrc | 2 +- libraries/o-error/buildscript.txt | 2 +- libraries/object-persistor/.nvmrc | 2 +- libraries/object-persistor/buildscript.txt | 2 +- libraries/overleaf-editor-core/.nvmrc | 2 +- .../overleaf-editor-core/buildscript.txt | 2 +- libraries/redis-wrapper/.nvmrc | 2 +- libraries/redis-wrapper/buildscript.txt | 2 +- libraries/settings/.nvmrc | 2 +- libraries/settings/buildscript.txt | 2 +- package-lock.json | 38 +++++++++---------- services/chat/.nvmrc | 2 +- services/chat/Dockerfile | 2 +- services/chat/buildscript.txt | 2 +- services/chat/docker-compose.yml | 4 +- services/clsi/.nvmrc | 2 +- services/clsi/Dockerfile | 2 +- services/clsi/buildscript.txt | 2 +- services/contacts/.nvmrc | 2 +- services/contacts/Dockerfile | 2 +- services/contacts/buildscript.txt | 2 +- services/contacts/docker-compose.yml | 4 +- services/docstore/.nvmrc | 2 +- services/docstore/Dockerfile | 2 +- services/docstore/buildscript.txt | 2 +- services/docstore/docker-compose.yml | 4 +- services/document-updater/.nvmrc | 2 +- services/document-updater/Dockerfile | 2 +- services/document-updater/buildscript.txt | 2 +- services/document-updater/docker-compose.yml | 4 +- services/filestore/.nvmrc | 2 +- services/filestore/Dockerfile | 2 +- services/filestore/buildscript.txt | 2 +- .../test/acceptance/js/FilestoreTests.js | 29 +++++++------- services/history-v1/.nvmrc | 2 +- services/history-v1/Dockerfile | 2 +- services/history-v1/buildscript.txt | 2 +- services/history-v1/docker-compose.yml | 4 +- services/notifications/.nvmrc | 2 +- services/notifications/Dockerfile | 2 +- services/notifications/buildscript.txt | 2 +- services/notifications/docker-compose.yml | 4 +- services/project-history/.nvmrc | 2 +- services/project-history/Dockerfile | 2 +- services/project-history/buildscript.txt | 2 +- services/project-history/docker-compose.yml | 4 +- services/real-time/.nvmrc | 2 +- services/real-time/Dockerfile | 2 +- services/real-time/buildscript.txt | 2 +- services/real-time/docker-compose.yml | 4 +- services/spelling/.nvmrc | 2 +- services/spelling/Dockerfile | 2 +- services/spelling/buildscript.txt | 2 +- services/spelling/install_deps.sh | 10 +---- .../spelling/test/acceptance/js/CheckTest.js | 21 +++++++++- services/track-changes/.nvmrc | 2 +- services/track-changes/Dockerfile | 2 +- services/track-changes/buildscript.txt | 2 +- services/track-changes/docker-compose.yml | 4 +- services/web/.nvmrc | 2 +- services/web/Dockerfile | 2 +- services/web/Dockerfile.frontend | 2 +- services/web/docker-compose.common.env | 2 +- services/web/docker-compose.yml | 4 +- services/web/scripts/translations/Dockerfile | 2 +- 71 files changed, 132 insertions(+), 120 deletions(-) diff --git a/libraries/access-token-encryptor/.nvmrc b/libraries/access-token-encryptor/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/access-token-encryptor/.nvmrc +++ b/libraries/access-token-encryptor/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/access-token-encryptor/buildscript.txt b/libraries/access-token-encryptor/buildscript.txt index 44d7e786e1..6fd14810e3 100644 --- a/libraries/access-token-encryptor/buildscript.txt +++ b/libraries/access-token-encryptor/buildscript.txt @@ -4,6 +4,6 @@ access-token-encryptor --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/logger/.nvmrc b/libraries/logger/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/logger/.nvmrc +++ b/libraries/logger/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/logger/buildscript.txt b/libraries/logger/buildscript.txt index 28eb541373..bad296357d 100644 --- a/libraries/logger/buildscript.txt +++ b/libraries/logger/buildscript.txt @@ -4,6 +4,6 @@ logger --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/metrics/.nvmrc b/libraries/metrics/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/metrics/.nvmrc +++ b/libraries/metrics/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/metrics/buildscript.txt b/libraries/metrics/buildscript.txt index e612e0f5f9..0caf9da5bb 100644 --- a/libraries/metrics/buildscript.txt +++ b/libraries/metrics/buildscript.txt @@ -4,6 +4,6 @@ metrics --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/o-error/.nvmrc b/libraries/o-error/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/o-error/.nvmrc +++ b/libraries/o-error/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/o-error/buildscript.txt b/libraries/o-error/buildscript.txt index d94c068a1c..6e36e7c759 100644 --- a/libraries/o-error/buildscript.txt +++ b/libraries/o-error/buildscript.txt @@ -4,6 +4,6 @@ o-error --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/object-persistor/.nvmrc b/libraries/object-persistor/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/object-persistor/.nvmrc +++ b/libraries/object-persistor/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/object-persistor/buildscript.txt b/libraries/object-persistor/buildscript.txt index 814c6b1640..f0e4a443d9 100644 --- a/libraries/object-persistor/buildscript.txt +++ b/libraries/object-persistor/buildscript.txt @@ -4,6 +4,6 @@ object-persistor --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/overleaf-editor-core/.nvmrc b/libraries/overleaf-editor-core/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/overleaf-editor-core/.nvmrc +++ b/libraries/overleaf-editor-core/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/overleaf-editor-core/buildscript.txt b/libraries/overleaf-editor-core/buildscript.txt index 1775946e52..4bcd0bd90b 100644 --- a/libraries/overleaf-editor-core/buildscript.txt +++ b/libraries/overleaf-editor-core/buildscript.txt @@ -4,6 +4,6 @@ overleaf-editor-core --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/redis-wrapper/.nvmrc b/libraries/redis-wrapper/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/redis-wrapper/.nvmrc +++ b/libraries/redis-wrapper/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/redis-wrapper/buildscript.txt b/libraries/redis-wrapper/buildscript.txt index d06f963b61..e024f9311e 100644 --- a/libraries/redis-wrapper/buildscript.txt +++ b/libraries/redis-wrapper/buildscript.txt @@ -4,6 +4,6 @@ redis-wrapper --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/libraries/settings/.nvmrc b/libraries/settings/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/libraries/settings/.nvmrc +++ b/libraries/settings/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/libraries/settings/buildscript.txt b/libraries/settings/buildscript.txt index 8052f6d2c1..f1d9077288 100644 --- a/libraries/settings/buildscript.txt +++ b/libraries/settings/buildscript.txt @@ -4,6 +4,6 @@ settings --env-add= --env-pass-through= --is-library=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/package-lock.json b/package-lock.json index b37b58e3a9..5876f48093 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15550,13 +15550,13 @@ "dev": true }, "node_modules/eslint-plugin-mocha": { - "version": "10.0.4", - "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.0.4.tgz", - "integrity": "sha512-8wzAeepVY027oBHz/TmBmUr7vhVqoC1KTFeDybFLhbaWKx+aQ7fJJVuUsqcUy+L+G+XvgQBJY+cbAf7hl5DF7Q==", + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.1.0.tgz", + "integrity": "sha512-xLqqWUF17llsogVOC+8C6/jvQ+4IoOREbN7ZCHuOHuD6cT5cDD4h7f2LgsZuzMAiwswWE21tO7ExaknHVDrSkw==", "dev": true, "dependencies": { "eslint-utils": "^3.0.0", - "ramda": "^0.28.0" + "rambda": "^7.1.0" }, "engines": { "node": ">=14.0.0" @@ -27042,15 +27042,11 @@ "node": ">=4" } }, - "node_modules/ramda": { - "version": "0.28.0", - "resolved": "https://registry.npmjs.org/ramda/-/ramda-0.28.0.tgz", - "integrity": "sha512-9QnLuG/kPVgWvMQ4aODhsBUFKOUmnbUnsSXACv+NCQZcHbeb+v8Lodp8OVxtRULN1/xOyYLLaL6npE6dMq5QTA==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/ramda" - } + "node_modules/rambda": { + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/rambda/-/rambda-7.5.0.tgz", + "integrity": "sha512-y/M9weqWAH4iopRd7EHDEQQvpFPHj1AA3oHozE9tfITHUtTR7Z9PSlIRRG2l1GuW7sefC1cXFfIcF+cgnShdBA==", + "dev": true }, "node_modules/random-bytes": { "version": "1.0.0", @@ -53039,13 +53035,13 @@ } }, "eslint-plugin-mocha": { - "version": "10.0.4", - "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.0.4.tgz", - "integrity": "sha512-8wzAeepVY027oBHz/TmBmUr7vhVqoC1KTFeDybFLhbaWKx+aQ7fJJVuUsqcUy+L+G+XvgQBJY+cbAf7hl5DF7Q==", + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.1.0.tgz", + "integrity": "sha512-xLqqWUF17llsogVOC+8C6/jvQ+4IoOREbN7ZCHuOHuD6cT5cDD4h7f2LgsZuzMAiwswWE21tO7ExaknHVDrSkw==", "dev": true, "requires": { "eslint-utils": "^3.0.0", - "ramda": "^0.28.0" + "rambda": "^7.1.0" }, "dependencies": { "eslint-utils": { @@ -62174,10 +62170,10 @@ "resolved": "https://registry.npmjs.org/quick-lru/-/quick-lru-1.1.0.tgz", "integrity": "sha1-Q2CxfGETatOAeDl/8RQW4Ybc+7g=" }, - "ramda": { - "version": "0.28.0", - "resolved": "https://registry.npmjs.org/ramda/-/ramda-0.28.0.tgz", - "integrity": "sha512-9QnLuG/kPVgWvMQ4aODhsBUFKOUmnbUnsSXACv+NCQZcHbeb+v8Lodp8OVxtRULN1/xOyYLLaL6npE6dMq5QTA==", + "rambda": { + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/rambda/-/rambda-7.5.0.tgz", + "integrity": "sha512-y/M9weqWAH4iopRd7EHDEQQvpFPHj1AA3oHozE9tfITHUtTR7Z9PSlIRRG2l1GuW7sefC1cXFfIcF+cgnShdBA==", "dev": true }, "random-bytes": { diff --git a/services/chat/.nvmrc b/services/chat/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/chat/.nvmrc +++ b/services/chat/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/chat/Dockerfile b/services/chat/Dockerfile index 87c955871b..b3ef0ab68b 100644 --- a/services/chat/Dockerfile +++ b/services/chat/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/chat diff --git a/services/chat/buildscript.txt b/services/chat/buildscript.txt index 25a0022096..d50a655169 100644 --- a/services/chat/buildscript.txt +++ b/services/chat/buildscript.txt @@ -3,6 +3,6 @@ chat --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/services/chat/docker-compose.yml b/services/chat/docker-compose.yml index 99738494e6..f88fe44b97 100644 --- a/services/chat/docker-compose.yml +++ b/services/chat/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/chat - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/chat - ../../node_modules:/overleaf/node_modules diff --git a/services/clsi/.nvmrc b/services/clsi/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/clsi/.nvmrc +++ b/services/clsi/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/clsi/Dockerfile b/services/clsi/Dockerfile index 1b773d9ad7..f61085761b 100644 --- a/services/clsi/Dockerfile +++ b/services/clsi/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/clsi COPY services/clsi/install_deps.sh /overleaf/services/clsi/ diff --git a/services/clsi/buildscript.txt b/services/clsi/buildscript.txt index b1abcffac9..e03a1acb5d 100644 --- a/services/clsi/buildscript.txt +++ b/services/clsi/buildscript.txt @@ -5,6 +5,6 @@ clsi --env-add=ENABLE_PDF_CACHING="true",PDF_CACHING_ENABLE_WORKER_POOL="true" --env-pass-through=TEXLIVE_IMAGE --has-custom-cloudbuild=True ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/contacts/.nvmrc b/services/contacts/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/contacts/.nvmrc +++ b/services/contacts/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/contacts/Dockerfile b/services/contacts/Dockerfile index 2091a63333..8c10323be0 100644 --- a/services/contacts/Dockerfile +++ b/services/contacts/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/contacts diff --git a/services/contacts/buildscript.txt b/services/contacts/buildscript.txt index 36c2789b55..ed2a0c4c57 100644 --- a/services/contacts/buildscript.txt +++ b/services/contacts/buildscript.txt @@ -3,6 +3,6 @@ contacts --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/services/contacts/docker-compose.yml b/services/contacts/docker-compose.yml index 745b8ff710..e80e794f8d 100644 --- a/services/contacts/docker-compose.yml +++ b/services/contacts/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/contacts - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/contacts - ../../node_modules:/overleaf/node_modules diff --git a/services/docstore/.nvmrc b/services/docstore/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/docstore/.nvmrc +++ b/services/docstore/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/docstore/Dockerfile b/services/docstore/Dockerfile index 6cdbb3c82f..1e72901bbd 100644 --- a/services/docstore/Dockerfile +++ b/services/docstore/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/docstore diff --git a/services/docstore/buildscript.txt b/services/docstore/buildscript.txt index e875521c33..e47ec833d4 100644 --- a/services/docstore/buildscript.txt +++ b/services/docstore/buildscript.txt @@ -3,6 +3,6 @@ docstore --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/docstore/docker-compose.yml b/services/docstore/docker-compose.yml index e95e5f11e6..d2b9f6cd70 100644 --- a/services/docstore/docker-compose.yml +++ b/services/docstore/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/docstore - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/docstore - ../../node_modules:/overleaf/node_modules diff --git a/services/document-updater/.nvmrc b/services/document-updater/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/document-updater/.nvmrc +++ b/services/document-updater/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/document-updater/Dockerfile b/services/document-updater/Dockerfile index fd460d5153..aa5a6015eb 100644 --- a/services/document-updater/Dockerfile +++ b/services/document-updater/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/document-updater diff --git a/services/document-updater/buildscript.txt b/services/document-updater/buildscript.txt index 28c5cf434d..b4ceb54d7e 100644 --- a/services/document-updater/buildscript.txt +++ b/services/document-updater/buildscript.txt @@ -3,6 +3,6 @@ document-updater --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/document-updater/docker-compose.yml b/services/document-updater/docker-compose.yml index 23e2797aa5..51f7fa0205 100644 --- a/services/document-updater/docker-compose.yml +++ b/services/document-updater/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/document-updater - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/document-updater - ../../node_modules:/overleaf/node_modules diff --git a/services/filestore/.nvmrc b/services/filestore/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/filestore/.nvmrc +++ b/services/filestore/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/filestore/Dockerfile b/services/filestore/Dockerfile index 93d2766e9b..4b4a7d8383 100644 --- a/services/filestore/Dockerfile +++ b/services/filestore/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/filestore COPY services/filestore/install_deps.sh /overleaf/services/filestore/ diff --git a/services/filestore/buildscript.txt b/services/filestore/buildscript.txt index 86e2285f74..03c9a1f054 100644 --- a/services/filestore/buildscript.txt +++ b/services/filestore/buildscript.txt @@ -4,6 +4,6 @@ filestore --docker-repos=gcr.io/overleaf-ops --env-add=ENABLE_CONVERSIONS="true",USE_PROM_METRICS="true",AWS_S3_USER_FILES_BUCKET_NAME=fake_user_files,AWS_S3_TEMPLATE_FILES_BUCKET_NAME=fake_template_files,AWS_S3_PUBLIC_FILES_BUCKET_NAME=fake_public_files,GCS_USER_FILES_BUCKET_NAME=fake_userfiles,GCS_TEMPLATE_FILES_BUCKET_NAME=fake_templatefiles,GCS_PUBLIC_FILES_BUCKET_NAME=fake_publicfiles --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/filestore/test/acceptance/js/FilestoreTests.js b/services/filestore/test/acceptance/js/FilestoreTests.js index ab9261901c..a0232a40c1 100644 --- a/services/filestore/test/acceptance/js/FilestoreTests.js +++ b/services/filestore/test/acceptance/js/FilestoreTests.js @@ -13,11 +13,9 @@ const streamifier = require('streamifier') chai.use(require('chai-as-promised')) const { ObjectId } = require('mongodb') const tk = require('timekeeper') -const ChildProcess = require('child_process') const fsWriteFile = promisify(fs.writeFile) const fsStat = promisify(fs.stat) -const exec = promisify(ChildProcess.exec) const msleep = promisify(setTimeout) if (!process.env.AWS_ACCESS_KEY_ID) { @@ -42,19 +40,24 @@ describe('Filestore', function () { async function expectNoSockets() { try { await msleep(1000) - const { stdout } = await exec('ss -tnH') - + const stdout = await fs.promises.readFile('/proc/net/tcp', 'utf8') const badSockets = [] - for (const socket of stdout.split('\n')) { - const fields = socket.split(' ').filter(part => part !== '') - if ( - fields.length > 2 && - parseInt(fields[1]) && - !seenSockets.includes(socket) - ) { - badSockets.push(socket) - seenSockets.push(socket) + const lines = stdout.split('\n').map(line => line.trim().split(/\s+/)) + const header = lines.shift() + if (header[4] === 'tx_queue' && header[5] === 'rx_queue') { + for (const socket of lines) { + if ( + socket.length > 5 && + socket[4] !== '00000000:00000000' && // ensure the socket queues are empty + !seenSockets.includes(socket) + ) { + console.log('socket still has data', socket) + badSockets.push(socket) + seenSockets.push(socket) + } } + } else { + throw new Error('unexpected format in /proc/net/tcp') } if (badSockets.length) { diff --git a/services/history-v1/.nvmrc b/services/history-v1/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/history-v1/.nvmrc +++ b/services/history-v1/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/history-v1/Dockerfile b/services/history-v1/Dockerfile index 6a89ff890a..e5ca3edb27 100644 --- a/services/history-v1/Dockerfile +++ b/services/history-v1/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/history-v1 diff --git a/services/history-v1/buildscript.txt b/services/history-v1/buildscript.txt index a0f67d781a..622247a330 100644 --- a/services/history-v1/buildscript.txt +++ b/services/history-v1/buildscript.txt @@ -3,6 +3,6 @@ history-v1 --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/services/history-v1/docker-compose.yml b/services/history-v1/docker-compose.yml index 8ba1f14b34..d440d14433 100644 --- a/services/history-v1/docker-compose.yml +++ b/services/history-v1/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/history-v1 - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/history-v1 - ../../node_modules:/overleaf/node_modules diff --git a/services/notifications/.nvmrc b/services/notifications/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/notifications/.nvmrc +++ b/services/notifications/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/notifications/Dockerfile b/services/notifications/Dockerfile index e0ced2119c..f61a1d7889 100644 --- a/services/notifications/Dockerfile +++ b/services/notifications/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/notifications diff --git a/services/notifications/buildscript.txt b/services/notifications/buildscript.txt index 06a2ce3bee..1ab741517e 100644 --- a/services/notifications/buildscript.txt +++ b/services/notifications/buildscript.txt @@ -3,6 +3,6 @@ notifications --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/notifications/docker-compose.yml b/services/notifications/docker-compose.yml index d0044e081c..cea0d85744 100644 --- a/services/notifications/docker-compose.yml +++ b/services/notifications/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/notifications - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/notifications - ../../node_modules:/overleaf/node_modules diff --git a/services/project-history/.nvmrc b/services/project-history/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/project-history/.nvmrc +++ b/services/project-history/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/project-history/Dockerfile b/services/project-history/Dockerfile index ebce9db91f..b26570e085 100644 --- a/services/project-history/Dockerfile +++ b/services/project-history/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/project-history diff --git a/services/project-history/buildscript.txt b/services/project-history/buildscript.txt index 5cb01f49ea..2559100172 100644 --- a/services/project-history/buildscript.txt +++ b/services/project-history/buildscript.txt @@ -3,6 +3,6 @@ project-history --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/services/project-history/docker-compose.yml b/services/project-history/docker-compose.yml index 3444430bcf..d2851345b9 100644 --- a/services/project-history/docker-compose.yml +++ b/services/project-history/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/project-history - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/project-history - ../../node_modules:/overleaf/node_modules diff --git a/services/real-time/.nvmrc b/services/real-time/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/real-time/.nvmrc +++ b/services/real-time/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/real-time/Dockerfile b/services/real-time/Dockerfile index f597b5fe5a..dca88d0592 100644 --- a/services/real-time/Dockerfile +++ b/services/real-time/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/real-time diff --git a/services/real-time/buildscript.txt b/services/real-time/buildscript.txt index c442c0564a..29bc04f174 100644 --- a/services/real-time/buildscript.txt +++ b/services/real-time/buildscript.txt @@ -3,6 +3,6 @@ real-time --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/real-time/docker-compose.yml b/services/real-time/docker-compose.yml index 62102fbe38..f7482fe52c 100644 --- a/services/real-time/docker-compose.yml +++ b/services/real-time/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/real-time - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/real-time - ../../node_modules:/overleaf/node_modules diff --git a/services/spelling/.nvmrc b/services/spelling/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/spelling/.nvmrc +++ b/services/spelling/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/spelling/Dockerfile b/services/spelling/Dockerfile index e942dfa27b..9dbe01d4e3 100644 --- a/services/spelling/Dockerfile +++ b/services/spelling/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/spelling COPY services/spelling/install_deps.sh /overleaf/services/spelling/ diff --git a/services/spelling/buildscript.txt b/services/spelling/buildscript.txt index 8b3c1263d2..4ef4e95ae6 100644 --- a/services/spelling/buildscript.txt +++ b/services/spelling/buildscript.txt @@ -4,6 +4,6 @@ spelling --docker-repos=gcr.io/overleaf-ops --env-add= --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=False --script-version=4.1.0 diff --git a/services/spelling/install_deps.sh b/services/spelling/install_deps.sh index 559641bcf0..e0b696e38e 100644 --- a/services/spelling/install_deps.sh +++ b/services/spelling/install_deps.sh @@ -3,7 +3,7 @@ set -ex # Prefer Debian packages over Ubuntu packages -echo 'APT::Default-Release "buster";' >/etc/apt/apt.conf.d/default-release +echo 'APT::Default-Release "bullseye";' >/etc/apt/apt.conf.d/default-release # The following aspell packages exist in Ubuntu but not Debian: # aspell-af, aspell-id, aspell-nr, aspell-ns, aspell-st, aspell-tn, aspell-ts, aspell-xh @@ -11,11 +11,5 @@ echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu/ focal main universe" > echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ focal main universe" > /etc/apt/sources.list.d/focal-ports-arm.list apt-key adv --no-tty --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32 -# aspell-pt-pt is broken in buster, we'll obtain it from bullseye -echo "deb http://deb.debian.org/debian bullseye main" > /etc/apt/sources.list.d/bullseye.list - apt-get update -apt-get install -y aspell aspell-en aspell-af aspell-ar aspell-ar-large aspell-bg aspell-br aspell-ca aspell-cs aspell-cy aspell-da aspell-de aspell-de-1901 aspell-el aspell-eo aspell-es aspell-et aspell-eu-es aspell-fa aspell-fo aspell-fr aspell-ga aspell-gl-minimos aspell-hr aspell-hsb aspell-id aspell-it aspell-kk aspell-ku aspell-lt aspell-lv aspell-nl aspell-no aspell-nr aspell-ns aspell-pa aspell-pl aspell-pt-br aspell-ro aspell-ru aspell-sk aspell-sl aspell-st aspell-sv aspell-tl aspell-tn aspell-ts aspell-xh - -# aspell-pt-pt is broken in buster. Install it from bullseye -apt-get install -y -t bullseye aspell-pt-pt +apt-get install -y aspell aspell-en aspell-af aspell-ar aspell-ar-large aspell-bg aspell-br aspell-ca aspell-cs aspell-cy aspell-da aspell-de aspell-de-1901 aspell-el aspell-eo aspell-es aspell-et aspell-eu-es aspell-fa aspell-fo aspell-fr aspell-ga aspell-gl-minimos aspell-hr aspell-hsb aspell-id aspell-it aspell-kk aspell-ku aspell-lt aspell-lv aspell-nl aspell-no aspell-nr aspell-ns aspell-pa aspell-pl aspell-pt-br aspell-pt-pt aspell-ro aspell-ru aspell-sk aspell-sl aspell-st aspell-sv aspell-tl aspell-tn aspell-ts aspell-xh diff --git a/services/spelling/test/acceptance/js/CheckTest.js b/services/spelling/test/acceptance/js/CheckTest.js index 0096209068..2e05a98692 100644 --- a/services/spelling/test/acceptance/js/CheckTest.js +++ b/services/spelling/test/acceptance/js/CheckTest.js @@ -27,7 +27,26 @@ describe('checking words', function () { it('should return the list of misspellings', async function () { const body = JSON.parse(response.body) expect(body).to.deep.equal({ - misspellings: [{ index: 0, suggestions: ['anther', 'another'] }], + misspellings: [ + { + index: 0, + suggestions: [ + 'anther', + 'another', + 'anthers', + 'panther', + 'anathema', + 'anthem', + 'nether', + "anther's", + 'ante', + 'neither', + 'norther', + 'ether', + 'other', + ], + }, + ], }) }) }) diff --git a/services/track-changes/.nvmrc b/services/track-changes/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/track-changes/.nvmrc +++ b/services/track-changes/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/track-changes/Dockerfile b/services/track-changes/Dockerfile index 06b522f338..02f0a7b95c 100644 --- a/services/track-changes/Dockerfile +++ b/services/track-changes/Dockerfile @@ -2,7 +2,7 @@ # Instead run bin/update_build_scripts from # https://github.com/overleaf/internal/ -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/track-changes diff --git a/services/track-changes/buildscript.txt b/services/track-changes/buildscript.txt index 8c0101898d..6b9c2e2ff3 100644 --- a/services/track-changes/buildscript.txt +++ b/services/track-changes/buildscript.txt @@ -3,6 +3,6 @@ track-changes --docker-repos=gcr.io/overleaf-ops --env-add=AWS_BUCKET=bucket --env-pass-through= ---node-version=16.17.1 +--node-version=18.16.0 --public-repo=True --script-version=4.1.0 diff --git a/services/track-changes/docker-compose.yml b/services/track-changes/docker-compose.yml index 10da1e6a79..8c1903d590 100644 --- a/services/track-changes/docker-compose.yml +++ b/services/track-changes/docker-compose.yml @@ -6,7 +6,7 @@ version: "2.3" services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/track-changes - ../../node_modules:/overleaf/node_modules @@ -20,7 +20,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/track-changes - ../../node_modules:/overleaf/node_modules diff --git a/services/web/.nvmrc b/services/web/.nvmrc index c85fa1bbef..6d80269a4f 100644 --- a/services/web/.nvmrc +++ b/services/web/.nvmrc @@ -1 +1 @@ -16.17.1 +18.16.0 diff --git a/services/web/Dockerfile b/services/web/Dockerfile index 4786ecf754..db93992303 100644 --- a/services/web/Dockerfile +++ b/services/web/Dockerfile @@ -1,6 +1,6 @@ # the base image is suitable for running web with /overleaf/services/web bind # mounted -FROM node:16.17.1 as base +FROM node:18.16.0 as base WORKDIR /overleaf/services/web diff --git a/services/web/Dockerfile.frontend b/services/web/Dockerfile.frontend index d8ac84abd1..c60119095a 100644 --- a/services/web/Dockerfile.frontend +++ b/services/web/Dockerfile.frontend @@ -1,4 +1,4 @@ -FROM node:16.17.1 +FROM node:18.16.0 # Install Google Chrome RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - diff --git a/services/web/docker-compose.common.env b/services/web/docker-compose.common.env index f9f94f8327..fce8a95bf1 100644 --- a/services/web/docker-compose.common.env +++ b/services/web/docker-compose.common.env @@ -41,5 +41,5 @@ SHARELATEX_SAML_UPDATE_USER_DETAILS_ON_LOGIN=true SHARELATEX_SAML_CERT=MIIDXTCCAkWgAwIBAgIJAOvOeQ4xFTzsMA0GCSqGSIb3DQEBCwUAMEUxCzAJBgNVBAYTAkdCMRMwEQYDVQQIDApTb21lLVN0YXRlMSEwHwYDVQQKDBhJbnRlcm5ldCBXaWRnaXRzIFB0eSBMdGQwHhcNMTYxMTE1MTQxMjU5WhcNMjYxMTE1MTQxMjU5WjBFMQswCQYDVQQGEwJHQjETMBEGA1UECAwKU29tZS1TdGF0ZTEhMB8GA1UECgwYSW50ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAxCT6MBe5G9VoLU8MfztOEbUhnwLp17ak8eFUqxqeXkkqtWB0b/cmIBU3xoQoO3dIF8PBzfqehqfYVhrNt/TFgcmDfmJnPJRL1RJWMW3VmiP5odJ3LwlkKbZpkeT3wZ8HEJIR1+zbpxiBNkbd2GbdR1iumcsHzMYX1A2CBj+ZMV5VijC+K4P0e9c05VsDEUtLmfeAasJAiumQoVVgAe/BpiXjICGGewa6EPFI7mKkifIRKOGxdRESwZZjxP30bI31oDN0cgKqIgSJtJ9nfCn9jgBMBkQHu42WMuaWD4jrGd7+vYdX+oIfArs9aKgAH5kUGhGdew2R9SpBefrhbNxG8QIDAQABo1AwTjAdBgNVHQ4EFgQU+aSojSyyLChP/IpZcafvSdhj7KkwHwYDVR0jBBgwFoAU+aSojSyyLChP/IpZcafvSdhj7KkwDAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAQEABl3+OOVLBWMKs6PjA8lPuloWDNzSr3v76oUcHqAb+cfbucjXrOVsS9RJ0X9yxvCQyfM9FfY43DbspnN3izYhdvbJD8kKLNf0LA5st+ZxLfy0ACyL2iyAwICaqndqxAjQYplFAHmpUiu1DiHckyBPekokDJd+ze95urHMOsaGS5RWPoKJVE0bkaAeZCmEu0NNpXRSBiuxXSTeSAJfv6kyE/rkdhzUKyUl/cGQFrsVYfAFQVA+W6CKOh74ErSEzSHQQYndl7nD33snD/YqdU1ROxV6aJzLKCg+sdj+wRXSP2u/UHnM4jW9TGJfhO42jzL6WVuEvr9q4l7zWzUQKKKhtQ== # DEVICE_HISTORY_SECRET has been generated using: # NOTE: crypto.generateKeySync was added in v15, v16 is the next LTS release. -# $ docker run --rm node:16 --print 'require("crypto").generateKeySync("aes", { length: 256 }).export().toString("hex")' +# $ docker run --rm node:18 --print 'require("crypto").generateKeySync("aes", { length: 256 }).export().toString("hex")' DEVICE_HISTORY_SECRET=1b46e6cdf72db02845da06c9517c9cfbbfa0d87357479f4e1df3ce160bd54807 diff --git a/services/web/docker-compose.yml b/services/web/docker-compose.yml index a298cab572..eae5f7ee02 100644 --- a/services/web/docker-compose.yml +++ b/services/web/docker-compose.yml @@ -6,7 +6,7 @@ volumes: services: test_unit: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/web - ../../node_modules:/overleaf/node_modules @@ -21,7 +21,7 @@ services: user: node test_acceptance: - image: node:16.17.1 + image: node:18.16.0 volumes: - .:/overleaf/services/web - ../../node_modules:/overleaf/node_modules diff --git a/services/web/scripts/translations/Dockerfile b/services/web/scripts/translations/Dockerfile index b28b8b7167..0134cd11fa 100644 --- a/services/web/scripts/translations/Dockerfile +++ b/services/web/scripts/translations/Dockerfile @@ -1,4 +1,4 @@ -FROM node:16.17.1 +FROM node:18.16.0 WORKDIR /app/scripts/translations