From 66909377f664cecbcc2eacab502ea93d3fade78a Mon Sep 17 00:00:00 2001 From: David Beniamine <david.beniamine@tetras-libre.fr> Date: Tue, 8 Nov 2022 11:53:17 +0100 Subject: [PATCH] Annotot documentation --- .env.template | 10 ++++++++++ README.md | 11 +++++++++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/.env.template b/.env.template index 29d1820..d7a9586 100644 --- a/.env.template +++ b/.env.template @@ -16,3 +16,13 @@ HTTP_FOLDER=./www # hosts allowed to access ressources from $HTTP_FOLDER # * to allow all, http://localhost:$DEV_PORT to allow only devserver CORS_ALLOWED_HOSTS=http://localhost:$DEV_PORT +# Annotot configuration (annotation storage server +# ENV = development or production +ANNOTOT_ENV=development +ANNOTOT_PORT=3000 +ANNOTOT_LISTEN_IP=0.0.0.0 +# This is the host used by annotot request launched by the client using mirador +# It should be localhost on dev mode, an something like annotot.yourservice.com in production +ANNOTOT_HOST=localhost +# For production only +ANNOTOT_SECRET_KEY_BASE=insert-a-random-key-here diff --git a/README.md b/README.md index 155805f..e86549d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,14 @@ ## Mirador Video Annotation POC -Copy `.env.template` to `.env` and change variables to suit your need (you can skip the edit step) +Copy `.env.template` to `.env` and change variables to suit your need. + +You **MUST** set at least the `ANNOTOT_SECRET_KEY_BASE` to a random string, the rest is preconfigured for a local development environment. + +For production, one **also** need to setup : + ++ `COMPOSE_FILE` should be at least `docker-compose.yml:annotot.yml` ++ `ANNOTOT_ENV` should be `production` ++ `ANNOTOT_HOST` should be the public hostname of your annotot server Run `docker-compose up -d`, which will serve a mirador instance at `http://localhost:$PORT` (default port is 8080). @@ -16,4 +24,3 @@ Follow the previous instructions if you want to access ressources from `$HTTP_FO Edit `.env` (copy it from `.env.template` if needed), set `COMPOSE_FILE=docker-compose.yml:devserver.yml` and adapt `DEV_*` variables to your needs. Run `docker-compose up -d --build devserver`, which will serve a mirador instance at `http://localhost:$DEV_PORT` (default port is 9000) with live rebuild/reload enabled on each `src/` and `public/` files modifications. - -- GitLab