Skip to main content

Deployment

Deployment

  1. Pull annolive docker images. You need the private access key recived from our team to do this step.
    docker login -u annolive
    When prompted enter the access key as the Password. Then run the following to pull the latest images required for running annolive server.
    docker pull annolive/annolive:latest
    docker pull annolive/model-server:latest
  2. Remove any previous installation of Annolive (optional)
    sudo rm -R /opt/annolive/
  3. Create local directories for the databases and storage.
    sudo mkdir -p /opt/annolive/rabbitmq
    sudo mkdir -p /opt/annolive/postgresql
    sudo mkdir -p /opt/annolive/storage/media
    sudo mkdir -p /opt/annolive/storage/static
  4. First change directory into /opt/annolive/ and then generate docker compose and other config files by initializing Annolive.
    cd /opt/annolive
    docker run -v /opt/annolive/:/opt/annolive/ annolive/annolive:latest
    You will be able to see .env, docker-compose.yml files in /opt/annolive/ if initialization is successfull. Grant file permissions to host user:
    sudo chown -R 1000:1000 /opt/annolive
  5. Use editors like vim/nano/vs code and modify the environment file present at /opt/annolive/.env with your organization details.
    export COMPOSE_PROJECT_NAME="annolive"
    export DJANGO_SETTINGS_MODULE="core.settings.onprem"
    export DOMAIN_NAME="your organisation name"
    export ADMIN_EMAIL="email id of admin for annolive from your organization"
    export ADMIN_NAME="Name of admin"
    export LICENSE_KEY="Enter your license key here"
  6. Now setup the annolive server by running the following
    docker compose -f /opt/annolive/docker-compose.yml up -d
  7. Annolive services are up now. Enter the backend service with a bash terminal using following:
    docker compose -f /opt/annolive/docker-compose.yml exec backend /bin/bash
    Run the following commands one by one:
    pipenv run python manage.py collectstatic --noinput
    pipenv run python manage.py migrate
    pipenv run python setup.py
    Then exit the container by running exit
  8. That's it! Access annolive at http://localhost:8558 or http://127.0.0.1:8558

Stop/Restart server

  • Run the following to stop the server:
docker compose -f /opt/annolive/docker-compose.yml down
  • Run the following to restart the server:
docker compose -f /opt/annolive/docker-compose.yml up -d

Uninstall Annolive

Do following steps for a clean uninstall of Annolive.

danger

You will permenantly lose all of your data if your perform the following steps, Advised to take a backup before this step so that you can restore if needed.

  1. Stop the Annolive server.
docker compose -f /opt/annolive/docker-compose.yml down
  1. Delete all data and config.
sudo rm -rf /opt/annolive/ 
  1. Delete docker images
docker images -q annolive/annolive | xargs docker rmi