Comment on Selfhosting Overleaf

november@iusearchlinux.fyi ⁨11⁩ ⁨months⁩ ago

There’s some tinkering with their docker-compose.yml to make it work. Here’s mine you can copy if you want to get it up and running. I don’t use nginx or any reverse-proxy btw:

services:
    sharelatex:
        restart: always
        image: sharelatex/sharelatex
        depends_on:
            mongo:
                condition: service_healthy
            redis:
                condition: service_started
        ports:
            - *DESIRED_PORT*:80
        links:
            - mongo
            - redis
        stop_grace_period: 60s
        volumes:
            - data:/var/lib/sharelatex
        environment:
            SHARELATEX_APP_NAME: Overleaf Community Edition
            SHARELATEX_MONGO_URL: mongodb://mongo/sharelatex
            SHARELATEX_REDIS_HOST: redis
            REDIS_HOST: redis
            ENABLED_LINKED_FILE_TYPES: 'project_file,project_output_file'
            ENABLE_CONVERSIONS: 'true'
            EMAIL_CONFIRMATION_DISABLED: 'true'

    mongo:
        command: "--replSet overleaf"
        restart: always
        image: mongo:4.4
        expose:
            - 27017
        volumes:
            - mongo_data:/data/db
        healthcheck:
            test: echo 'db.stats().ok' | mongo localhost:27017/test --quiet
            interval: 10s
            timeout: 10s
            retries: 5

    redis:
        restart: always
        image: redis:6.2
        expose:
            - 6379
        volumes:
            - redis_data:/data

volumes:
  data:
  mongo_data:
  redis_data:

Some of my documents relied on certain packages which don’t come with Docker image. You will need to run docker exec sharelatex-sharelatex-1 tlmgr install scheme-full so that you can render your documents properly if they utilize certain packages.

source
Sort:hotnewtop