Commit graph

19060 commits

Author SHA1 Message Date
Winston Li
6c71c2cb97 Add ning http headers class 2018-01-17 09:47:31 +00:00
Winston Li
34e558ab63 Create noop db store and test file 2018-01-17 09:47:31 +00:00
Winston Li
4e7636c94a Decouple http client from UrlResourceCache 2018-01-17 09:47:31 +00:00
Winston Li
ae65212f19 Create http client facade 2018-01-17 09:47:31 +00:00
Winston Li
11ee9c62a3 Update README for repoStore option 2018-01-17 09:46:40 +00:00
Michael Walker
1e4ef0cc5b Fully implement max file size
- add `repoStore.maxFileSize` key to config
- use maxFileSize in ResourceCache on both header path and blob
  download path
- make failures during commit less fragile
2018-01-17 09:46:40 +00:00
Michael Walker
dc93df6bc8 Merge pull request #35 from overleaf/msw-refactor_24
#24 Part 3/6: refactor
2018-01-17 09:37:25 +00:00
John Lees-Miller
72f8fb553c Fix typos 2018-01-16 18:30:17 +00:00
James Allen
c420916c17 Merge pull request #47 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:09:07 +00:00
James Allen
2aac6afca4 Merge pull request #11 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:54 +00:00
James Allen
e8b6d033ec Merge pull request #27 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:49 +00:00
James Allen
7a9dcc81c2 Merge pull request #4 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:43 +00:00
James Allen
980e1a5d6a Merge pull request #27 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:36 +00:00
James Allen
6d44176ab5 Merge pull request #17 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:30 +00:00
James Allen
a47894636b Merge pull request #29 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:23 +00:00
James Allen
274616780a Merge pull request #4 from sharelatex/ja-dockerize-dev
Provide hosts as environment settings and add npm run start script
2018-01-16 17:08:16 +00:00
James Allen
64ad02b1bf Merge pull request #83 from sharelatex/ja-dockerize-dev
Provide hosts as settings and add npm run start script
2018-01-16 17:08:09 +00:00
James Allen
35a861bfec Merge pull request #10 from sharelatex/ja-dockerize-dev
Provide hosts as settings and add npm run start script
2018-01-16 17:08:03 +00:00
Henry Oswald
77e34d33df hello james 2018-01-16 17:00:27 +00:00
Henry Oswald
08c734e850 another bump
git log
2018-01-16 14:48:21 +00:00
Henry Oswald
dbfebc0d1c bump 2018-01-16 14:36:09 +00:00
Henry Oswald
e235651e9c bump version 2018-01-16 12:44:26 +00:00
Henry Oswald
c23b700927 wip 2018-01-16 12:27:36 +00:00
James Allen
d0e5fb2d34 Allow texlive image user to be configured 2018-01-16 10:46:59 +00:00
James Allen
c466025df4 Go back to allowing v1 projects to be imported 2018-01-16 09:40:58 +00:00
Alasdair Smith
4a0628d801 Remove unnecessary test script 2018-01-15 16:23:10 +00:00
Alasdair Smith
984ecae200 Rename directory to es to align with coffee dir 2018-01-15 16:23:10 +00:00
Alasdair Smith
dadd74e730 Move public path to dev config 2018-01-15 16:23:10 +00:00
Alasdair Smith
4642d55b7b Add basic example script 2018-01-15 16:23:10 +00:00
Alasdair Smith
49c27c4c7a Port webpack config from OL 2018-01-15 16:23:10 +00:00
Alasdair Smith
9fbd7f2818 Install webpack and babel 2018-01-15 16:23:10 +00:00
James Allen
6d04eeaa03 Merge pull request #256 from sharelatex/ja-display-v2-history-users
Inject v2 user details into project-history updates and diffs
2018-01-15 14:21:14 +00:00
James Allen
67061154fe Merge pull request #237 from sharelatex/hof-editor-controller-locking
Project Locking: EditorController
2018-01-15 14:21:03 +00:00
Winston Li
6b94fcf1b4 Decouple Bridge from network, JGit from disk 2018-01-15 11:56:04 +00:00
Michael Walker
918e3d9975 Remove an unneeded import 2018-01-15 11:56:04 +00:00
Michael Walker
e437c14d72 Refactor ResourceFetcherTest 2018-01-15 11:56:04 +00:00
Michael Walker
17aff50cc9 Merge pull request #34 from overleaf/msw-file_too_big_fix
#24 Part 2/6: file too big fix
2018-01-15 11:45:31 +00:00
Michael Walker
1f35b6dec3 Raise an error if files exceed the max file size 2018-01-15 11:39:29 +00:00
Michael Walker
7e047042c0 Merge pull request #29 from winstonli/minor_fixes
#24 Part 1/6: minor fixes
2018-01-15 11:16:32 +00:00
James Allen
7de4df9702 Merge pull request #250 from sharelatex/ja-dockerize-dev
Improve local and CI build processes and make compatible with docker-compose workflow
2018-01-15 09:41:55 +00:00
James Allen
662122bb1c CI and local dev environment improvements
The need for this became very noticeable due to the slowness of filesystem access in docker-in-mac, with a full compile taking over a minute for me in docker. Using make to introduce incremental compile makes this near instantaneous outside of docker (if only a few files have changed), and quick enough inside docker.

With incremental compile via make, it compiles quickly enough that re-compiling and restarting the web service automatically when backend files change is quick enough now. This is how the service is run via docker-compose in https://github.com/sharelatex/sharelatex-dev-environment, so it shouldn't be necessary to manually restart the container each time a coffee file changes.

At the moment Jenkins pull web modules in via the GitSCM plugin, but I believe this is creating a dependency in Jenkins, where any commits to any of the modules causes all of the web branches to rebuild. By doing it via our own scripts we can hopefully avoid this. It also creates a build process which is reproducible locally.

**Note that at the moment in this PR all modules pull from `ja-dockerize-dev` branches, but these should be merged first, and this PR updated to point to the master branches before merging**. This is necessary for other changes to build process/docker-compose workflow.

As well as a Makefile for web, there is now a `Makefile.module`. This is copied into each module directory by the top-level Makefile, and is written in a way to be flexible and support unit tests, acceptance tests, front-end js for the ide and main, and the modules `app/coffee` directory, while allowing modules to have some of these missing (not all modules have e.g. acceptance tests, or front-end JS). This will allows us to refine the build process in future, without needing to update the Makefile in each module repo separately (I found this to be a painful part of this development).

This makes web compatible with the docker-compose workflow at https://github.com/sharelatex/sharelatex-dev-environment, where each service is running in its own docker container, with networking managed by docker.

Previously the Makefile was set up to run unit tests in docker with `make unit_tests`. This now just runs them natively. In the CI, they are run in docker anyway (all steps in Jenkins are), and locally, they run fine natively with `npm run test:unit`, or can be run in docker via https://github.com/sharelatex/sharelatex-dev-environment with `bin/run web_sl npm run test:unit`.

Previously we did a lot of juggling with only mounting source files (coffee, less, etc) into the docker container for acceptance tests. This was to avoid creating root owned files if the whole directory was mounted. Now instead the whole web directory is mounted read-only, with the compilation step done outside of the container before running the tests.

This allows the host and container to share the `node_modules` folder as well, which avoids needing to `npm install` twice on the CI box, and should speed up the build by a few minutes.

On macOS, this would cause a problem with compiled modules if you tried to use the same `node_modules` to run the app natively. However, if running via docker-compose in https://github.com/sharelatex/sharelatex-dev-environment, this is no longer a problem.
2018-01-15 09:36:41 +00:00
Timothée Alby
62bc3f947f Merge pull request #257 from sharelatex/ta-remove-proxy-headers
Remove headers when proxying analytics request
2018-01-12 15:48:18 +02:00
Hayden Faulds
e781779c24 use LockManager.runWithLock in EditorController 2018-01-12 10:53:36 +00:00
Hayden Faulds
76c7dff33a rename EditorController.replaceFile -> replaceFileWithoutLock 2018-01-12 10:06:18 +00:00
Hayden Faulds
a8818a4149 add locking for EditorController.renameEntity 2018-01-12 10:06:18 +00:00
Tim Alby
7a9d52b0f6 remove all headers when proxying the analytics request 2018-01-11 19:04:41 +02:00
Alberto Fernández-Capel
4dce9e36c3 Merge pull request #251 from sharelatex/fix-group-member-subscription-page
Fix subscription page for members of a group
2018-01-11 14:41:31 +00:00
Alberto Fernández-Capel
feaa7c6d3f Merge pull request #242 from sharelatex/rename-entity-bugfix
Ensure the dirname is not affected when we rename an entity
2018-01-11 14:41:21 +00:00
James Allen
8edef2f94d Fix next -> callback 2018-01-11 14:11:44 +00:00
James Allen
17a5dfa5a5 Inject v2 user details into project-history updates and diffs 2018-01-11 11:32:16 +00:00