version: "3.3" services: redis: image: docker.io/library/redis:alpine command: --save 60 1 --loglevel warning restart: unless-stopped healthcheck: test: ["CMD-SHELL", "redis-cli ping | grep PONG"] start_period: 20s interval: 30s retries: 5 timeout: 3s networks: - outline volumes: - {{ outline_volume_redis | expanduser | realpath }}:/data - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro {% if outline_db_schema == 'postgres' and outline_db_host == 'postgres' %} postgres: image: docker.io/library/postgres:12-alpine env_file: - "{{ outline_setup_path | expanduser | realpath }}/env.db.conf" restart: unless-stopped healthcheck: test: ["CMD-SHELL", "pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}"] start_period: 20s interval: 30s retries: 5 timeout: 5s networks: - outline {% if outline_db_port %} ports: - {{ outline_db_port }}:5432 {% endif %} volumes: - {{ outline_volume_db }}:/var/lib/postgresql/data {% else %} # External database at "{{ outline_db_schema }}:{{ outline_db_host }}: {{ outline_db_port }}" {% endif %} {% if outline_fake_s3 and (outline_fake_s3 != "") %} s3: image: lphoward/fake-s3 env_file: - "{{ outline_setup_path | expanduser | realpath }}/env.s3.conf" {% if outline_fake_s3_port %} ports: - {{ outline_fake_s3_port }}:4569 {% endif %} volumes: - {{ outline_volume_s3 | expanduser | realpath }}:/fakes3_root networks: - outline {% endif %} outline: image: outlinewiki/outline:latest command: sh -c "yarn start" # command: sh -c "yarn sequelize:migrate --env production-ssl-disabled && yarn start" env_file: - "{{ outline_setup_path | expanduser | realpath }}/env.outline.conf" - "{{ outline_setup_path | expanduser | realpath }}/env.oidc.conf" restart: always ports: - {{ outline_port }}:3000 depends_on: {% if outline_db_schema == 'postgres' and outline_db_host == 'postgres' %} - postgres {% endif %} - redis {% if outline_fake_s3 and (outline_fake_s3 != "") %} - s3 {% endif %} networks: - outline networks: outline: {}