63 Commits

Author SHA1 Message Date
claude 8fc71d677c Fix thumbnail quality and mobile vertical split layout
Build and Deploy Verso / deploy (push) Successful in 10m23s
Thumbnails: update the actual thumbnail endpoint (ConversionController.js
thumbnailFromBuild) to quality=90 and width=794. The previous fix targeted
ConversionManager.js which handles preview mode, not the thumbnail route
called by ThumbnailManager.mjs.

Mobile layout: move the isMobile guard before the stored-preference check
in getInitialLayout(). The autoSave race fix (build 274) stopped future
bad writes, but a stale 'flat' in localStorage was still being read on
every load, blocking the mobile check. Mobile now always starts in
verticalSplit regardless of any stored value.

CI: add node --check on all server-side .mjs files in the Dockerfile,
after source copy and before webpack compile, so syntax errors like the
escaped-backtick incident fail the build immediately.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-18 13:48:44 +00:00
claude 38edd5269c CI: retry Yarn Classic dep packing on transient esbuild fetch corruption
Build and Deploy Verso / deploy (push) Successful in 11m5s
Build #78 failed in the compile step while Yarn Classic prepared the
@replit/codemirror-* git deps: fetching esbuild's per-platform binaries
returned truncated tarballs ("the file appears to be corrupt" / missing
.yarn-tarball.tgz). The tmpfs classic cache is fresh each build, so there is no
stale entry to blame and nothing to fall back to — it is a transient download
failure (builds #75-77 passed with an identical Dockerfile).

Wrap both the install and compile steps in a 3-attempt retry loop that wipes
the Yarn Classic cache (/usr/local/share/.cache/yarn) and re-fetches before
giving up, dumping pack.log on final failure. The persistent Berry cache and
YARN_NETWORK_CONCURRENCY=1 are unchanged.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-02 20:03:51 +00:00
claude e0a4938a78 CI: make Yarn Classic fallback cache a tmpfs (fresh per build)
Build and Deploy Verso / deploy (push) Successful in 11m9s
#74 corrupted the persistent fallback cache again despite serialising the
fetch, so the cause isn't a write race: BuildKit evicts part of that persistent
cache mount between builds (the first build after each id bump always passed,
later ones failed). Mount /usr/local/share/.cache/yarn as tmpfs so it's clean
every build and nothing can be half-evicted; the Berry cache stays persistent.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-02 15:15:38 +00:00
claude 8b9fe4e760 CI: stop Yarn git-dep prepare from corrupting the shared fallback cache
Build and Deploy Verso / deploy (push) Successful in 12m50s
The web build's 'yarn install' re-prepares the git-sourced @replit/codemirror-*
deps whenever the Berry cache misses (BuildKit GCs it between builds). Each
prepare uses Yarn Classic, which pulls every esbuild platform binary into the
single shared /usr/local/share/.cache/yarn folder; running several prepares in
parallel races and corrupts it ('tar content corrupt', EEXIST, missing
.yarn-tarball.tgz). Bumping the cache id only cleared it until the next
cache-miss build (#69).

Serialise Yarn's fetch with YARN_NETWORK_CONCURRENCY=1 on the install and
compile steps so the prepares no longer write that cache concurrently, and bump
the fallback cache id (v2 -> v3) once more to discard the currently-corrupt
cache. Slightly slower fetch, but no more random cache corruption.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-02 12:20:35 +00:00
claude e3fb781042 CI: bust corrupted Yarn fallback build cache
Build and Deploy Verso / deploy (push) Successful in 8m0s
The web compile step failed packing the git-sourced @replit/codemirror-*
deps with 'tar content corrupt' / EEXIST / missing .yarn-tarball.tgz errors,
all under /usr/local/share/.cache/yarn/v6 — i.e. a corrupted BuildKit
fallback-cache mount (likely left half-written by an interrupted build), not
a code or dependency change. Bump the fallback cache id so BuildKit
allocates a fresh empty cache; the berry and webpack caches are untouched.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-02 10:07:14 +00:00
alois a2db1f04be Actualiser server-ce/Dockerfile
Build and Deploy Verso / deploy (push) Has been cancelled
2026-05-30 12:08:40 +00:00
alois ba5d159f28 Fix dockerfile ARG
Build and Deploy Verso / deploy (push) Has been cancelled
2026-05-29 20:40:57 +02:00
alois e4db4fe458 Fix corepack yarn install for build 2026-05-29 20:22:40 +02:00
Miguel Serrano 21902e7a55 [CE/SP] Remove non-production dependencies (#33949)
Some non-production dependencies were bundled in the CE and SP images:
- `lint` was pulled as production dependency by `eslint-plugin`. Moving to peer-dependency, which is the usual strategy, addresses the issue.
- Yarn cache wasn't purged. By adding `/usr/local/share/.cache/yarn` to the mounts we ensure it's also cleaned.

GitOrigin-RevId: f328592c8f8de7193295839578e239a975fe30aa
2026-05-28 08:06:51 +00:00
Jakob Ackermann 44efc9d745 [monorepo] avoid corepack network requests (#33502)
* [monorepo] avoid corepack network requests

- Download yarn via corepack as the first step in all the docker files
- Turn off networking in corepack
- Do not run things in the upstream node image
  Instead, use the monorepo image, or base layer in all the services.
- Always build the base layer when running tests (uses cache)

* [monorepo] install corepack in shared place

* [clsi-lb] remove unrelated changes

* [web] add missing DC_RUN_FLAGS

* [monorepo] only rebuild test images locally

Also remove spurious build config in docker-compose.ci.yml.

* [server-ce] test: make yarn files available to host-admin and e2e

* [monorepo] put the corepack install snippet in a few more places

GitOrigin-RevId: 38005016ae5a708e12295e246269d6c18fece937
2026-05-08 08:08:57 +00:00
Anna Claire Fields 0d64a88a46 Yarn 4 Migration (#32253)
Migrates the Overleaf monorepo package manager from npm (v11) to Yarn 4 (v4.9.1) using node-modules linker mode.

GitOrigin-RevId: 50d32ab01955c15e29679eff9e9e9cfb897fab2d
2026-04-28 08:52:37 +00:00
Daniel Kontšek 3584cf0465 Merge pull request #32172 from overleaf/dn0-fix-server-ce-dockerfile-syntax
[server-ce] fix Cloud Build by adding Dockerfile syntax directive

GitOrigin-RevId: 007c4fcf571165c7c1cea311771468662f022a43
2026-03-16 11:56:26 +00:00
Jakob Ackermann 3ddc20e424 [server-ce] run npm install on minimal set of source files (#31111)
GitOrigin-RevId: 389acfb3e23533f5361f2cc0274b440d785a7179
2026-01-29 09:06:39 +00:00
Brian Gough 729e0f5ac9 move migrations to shared location (#28306)
* fix: correct typedef for Document in helpers.mjs

* add move-migrations codemod

* update migration paths to use shared migrations directory

* move migrations to shared location

* fix: update Dockerfile and docker-compose.ci.yml to include migrations directory

* feat: add migrations tool to workspaces in package.json

* [monorepo] Fix order of docker ignore rules

* [web] remove unused docker ignore file

* [monorepo] replace old references to migrations folder

* [server-ce] copy migrations from new place

* [migrations] Inline web scripts

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] move three web scripts over

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] add missing collection

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] remove lodash dependency

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] avoid mongodb-legacy dependency

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [monorepo] run migrations from tools/migrations

Co-authored-by: Brian Gough <brian.gough@overleaf.com>

* [migrations] simplify migration for adding gitBridge feature to users

* [monorepo] run migrations from tests in all the services

* [migrations] add Jenkins pipeline for linting/formatting

* [monorepo] fixup running web migrations everywhere

* [monorepo] trigger Jenkins builds on changes to mongo migrations

* [migrations] add Jenkins pipeline for linting/formatting

* [monorepo] build scripts: update devDependencies before deps scanning

* [monorepo] build scripts: formerly depend on tools/migrations

* [monorepo] run eslint on .mjs files

* [migrations] enable more eslint rules and fix all the errors

* [rake] fix migrations:list task

---------

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 14cf69cc1b9405bbc75adbb9a000e555500e0614
2025-10-16 08:07:37 +00:00
Jakob Ackermann 2e2415c56e [server-pro] move revision from /var/www/revisions.txt into label (#27071)
Co-authored-by: Brian Gough <brian.gough@overleaf.com>
GitOrigin-RevId: d760498b50006a23f446a91647954d00fa22f2f2
2025-07-15 08:05:57 +00:00
Jakob Ackermann 18a052f224 Merge pull request #20551 from overleaf/jpa-docker-cleanup
[misc] fix deprecated syntax for ENV entries in all the Dockerfiles

GitOrigin-RevId: 1def5a4666435e7649b8b09557a445d016f3ef5a
2024-09-24 08:05:37 +00:00
Jimmy Domagala-Tang 7add11a190 Merge pull request #19642 from overleaf/jdt-latexmkrc-ce
feat: add latexmkrc for server-ce
GitOrigin-RevId: 0d7385808a6a0b98d0a759ce0e329e6b9f578f35
2024-09-04 08:05:55 +00:00
Jakob Ackermann 399e834e36 Merge pull request #19764 from overleaf/jpa-server-pro-cache
[server-pro] faster local build

GitOrigin-RevId: d71abde37253e4c0398afa6935290af79a1204be
2024-08-07 08:04:24 +00:00
Jakob Ackermann e36de5a62d Merge pull request #18856 from overleaf/jpa-server-ce-shutdown
[server-ce] improve shutdown procedure

GitOrigin-RevId: 5a99868d17f597c366e42625cd39f05146dcb682
2024-06-18 08:04:04 +00:00
Jakob Ackermann 2f5bcebcdd Merge pull request #18570 from overleaf/jpa-lean-npm-install
[server-ce] omit devDependencies from final image

GitOrigin-RevId: e35d7010ee33345121fb175e0400be122cb468c1
2024-05-31 08:04:00 +00:00
Jakob Ackermann 8eb8b233c0 Merge pull request #18316 from overleaf/jpa-host-admin
[server-ce] e2e tests: add capability for reconfiguring the instance

GitOrigin-RevId: 44ec800b5b37497b3122310a94f637c24ff2667a
2024-05-30 08:05:22 +00:00
Miguel Serrano cee678591f Merge pull request #18145 from overleaf/msm-ce-history-scripts
[CE] Add history utility scripts (flush/resync)

GitOrigin-RevId: 3f46609c279bef70f1ee6e63f74648f1c2b99a97
2024-04-30 08:04:38 +00:00
Miguel Serrano c22e6a5926 Merge pull request #17694 from overleaf/bg-ipv6-fix-editing
Force services to use ipv4 in server-ce container

GitOrigin-RevId: 9cf2734f8506bba15ef3ac11060508d2604d09ad
2024-04-04 08:04:06 +00:00
Jakob Ackermann 6d98d6a7c0 Merge pull request #16923 from overleaf/jpa-server-pro-fs-rebranding
[server-pro] remove ShareLaTeX branding from filesystem

GitOrigin-RevId: c1d2c63bdc888d81e03bb1721e44b6ed6f64524b
2024-02-12 09:03:39 +00:00
Miguel Serrano 2833a8ce61 [CE] Rename base image to OVERLEAF_BASE_TAG
SHARELATEX_BASE_TAG was renamed to OVERLEAF_BASE_TAG
in the cloudbuild files in https://github.com/overleaf/internal/pull/16823, but the docker image
was never updated.

GitOrigin-RevId: 8690623addafd5d76ffb310c863abbbf72dbb938
2024-02-09 09:05:59 +00:00
mserranom 389eb9105b [CE/SP] Rebrand common env variables to Overleaf
GitOrigin-RevId: 92439946f909f115df26a2bad79269f88741a9ac
2024-02-09 09:05:37 +00:00
Jakob Ackermann 63520c7076 Merge pull request #16859 from overleaf/jpa-sharelatex-cleanup
[misc] ShareLaTeX cleanup - high impact

GitOrigin-RevId: 6dcce9b0f15e30f7afcf6d69c3df36a369f38120
2024-02-09 09:04:11 +00:00
Miguel Serrano 9eb8743014 Merge pull request #15531 from overleaf/msm-sp-hotfix-4-1-6
[CE/SP] Hotfix 4.1.6

GitOrigin-RevId: dc023665d5e0868913eff2104de1acaf7038cb9f
2023-11-02 08:53:07 +00:00
Miguel Serrano 5fdc43e342 Merge pull request #13370 from overleaf/msm-remove-history-flags-ce
[CE] Remove `SHARELATEX_FPH_` env variables

GitOrigin-RevId: 8e356eb65481de95dc1185f1e0ce081ef9b470b0
2023-07-17 10:28:23 +00:00
Miguel Serrano 11dc9712eb Merge pull request #11473 from overleaf/msm-ce-deletion-cron
[CE/SP] `cron` jobs for resource deletion

GitOrigin-RevId: 7d690340f11cb4aaf38653fdcca6b7944f9a4d0b
2023-05-10 08:06:00 +00:00
Eric Mc Sween 6c234e81c0 Merge pull request #12377 from overleaf/em-server-pro-config
Config adjustments for git bridge in Server Pro

GitOrigin-RevId: 1fc4563253252e5a05118d8fda99a00c8b22126a
2023-04-04 08:05:01 +00:00
Jakob Ackermann 32661eb8c2 Merge pull request #12034 from overleaf/jpa-history-cleanup
[server-ce] delete config for not needed buckets

GitOrigin-RevId: 4eaed05f8c8b54bf52e1b18858f0c4e2177eaf5e
2023-03-01 09:03:49 +00:00
Christopher Hoskin 9ac982cda7 Merge pull request #11860 from overleaf/jpa-cleanup-history-analytics
[history-v1] delete count_blob_references script and related infra

GitOrigin-RevId: f1fb41600486d2b22fa47b922b8895c0ae8e9288
2023-02-22 09:04:14 +00:00
Miguel Serrano 976e0d5e8f [CE] Set Phusion Image timeouts in Dockerfile (#11785)
GitOrigin-RevId: 6ce852e44093d44e66d9f394c6ef4ef9d88d1373
2023-02-10 16:33:50 +00:00
Jakob Ackermann 4e885da597 Merge pull request #11782 from overleaf/jpa-server-ce-history-s3
[server-ce] s3 settings for history-v1

GitOrigin-RevId: 51d5c6b3a67339b126ccbaa61d78f3cd36377e79
2023-02-10 16:33:43 +00:00
Tim Down 7c7f8c1573 Merge pull request #11733 from overleaf/msm-close-site-sp-shutdwn
[CE/SP] close site on shutdown before flushing

GitOrigin-RevId: e36c80f2f4c6f10eda3a536319a2fcc5dfda4fa4
2023-02-09 09:07:07 +00:00
Miguel Serrano 909bb99b9f [CE/SP] Flush redis on docker stop (#11714)
* [CE/SP] Flush redis on `docker stop`

* Extracted `limit` to variable

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>

* Increased logging

---------

Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 4bcb4e70988337369acca0e80f243609bd6323ed
2023-02-09 09:06:37 +00:00
Miguel Serrano 064e5c9222 Merge pull request #11682 from overleaf/msm-fph-opt-in-sp
[CE/SP] Full Project History opt-in in SP

GitOrigin-RevId: 850268b78e912550dbf9d36e61ee83c7e75e4647
2023-02-07 09:55:29 +00:00
Miguel Serrano d9b851fb9e Merge pull request #11538 from overleaf/msm-crontab-permission
[CE] changed `crontab` permissions to `600`

GitOrigin-RevId: 38e145fe0d15cc1859096232bd8754e81726be2d
2023-01-31 10:35:16 +00:00
Miguel Serrano 28c9c32e1b Merge pull request #11448 from overleaf/msm-sp-cron
[CE/SP] `cron` jobs for Full Project History

GitOrigin-RevId: 1f52bd4baaed5856193cd3babfe2c95865b25cf8
2023-01-26 11:39:16 +00:00
Miguel Serrano 4a84922a2f Merge pull request #11346 from overleaf/msm-config-history-v1-sp
Configuration changes for FPH in CE/SP

GitOrigin-RevId: 990eb0fa6158d4815740413da085759d2cc5e231
2023-01-20 14:13:46 +00:00
Timothée Alby 1ae3061f16 Merge pull request #9972 from overleaf/jpa-fix-rate-limited-output-download
[server-ce] serve output files via nginx

GitOrigin-RevId: 0ba3b27f85f928b1d95646e663dfa42a22a9f832
2022-10-18 08:03:09 +00:00
Alf Eaton 85e2ec0f8c Merge pull request #9156 from overleaf/ae-server-ce-cypress
Prevent Cypress binary download when building Server CE Docker image

GitOrigin-RevId: 8438dabef844a7251192b76078e677f25b00c0d0
2022-08-09 08:02:44 +00:00
Alf Eaton 9884cc8c76 Merge pull request #8927 from overleaf/ae-server-ce-npm-version
Remove npm v7 install from server-ce Dockerfile

GitOrigin-RevId: be980547d134dc383518f4bd88165afbae7543d7
2022-07-22 08:03:06 +00:00
Jakob Ackermann e82a053c85 Merge pull request #6614 from overleaf/jpa-msm-separate-admin-app
[misc] move admin capability from www. to admin. subdomain

GitOrigin-RevId: e0daeacf3c06b856ffb9fd35dce76e71f14e8459
2022-04-05 12:18:24 +00:00
Miguel Serrano 8d1e4ce200 Merge pull request #6829 from overleaf/msm-remove-ce-workdir
[serve-ce] remove final WORKDIR statement

GitOrigin-RevId: 6e243a814409adba8c3bacfd99400f537f301e25
2022-02-18 12:41:18 +00:00
Jakob Ackermann ae0c347f27 Merge pull request #6542 from overleaf/jpa-em-code-sharing-workspaces
[misc] npm workspaces

GitOrigin-RevId: 87aa72db6637fb238d7cd35b0a48ac3ed58ab3eb
2022-02-16 11:31:07 +00:00
Jakob Ackermann d5dd92c034 Merge pull request #6567 from overleaf/jpa-server-ce-pro-layout
[misc] align directory layout of server-ce/pro with production docker images

GitOrigin-RevId: d3e6b9f8793e83df59f86105d511c6fb87c3eea3
2022-02-02 09:03:33 +00:00
Jakob Ackermann 603698ed32 Merge pull request #5163 from overleaf/jpa-fix-server-ce-pro
[misc] set NODE_ENV=production for server-ce/server-pro

GitOrigin-RevId: dadedbcffb91d467ff93d501bb458448ad3b8dbf
2021-09-22 08:03:47 +00:00
Eric Mc Sween 9ee92daea3 Merge pull request #4893 from overleaf/em-synctex
Use the synctex distributed with TeX Live

GitOrigin-RevId: 5a133f21f48fd1e217ab463e8cb2a5cdec8be1af
2021-09-07 16:26:17 +00:00