1_Installation

Last modified by Jan Brinkhaus on 2023/03/27 11:03

Prerequisite: Docker installation

FileSync is deployed as docker container. You need a running docker installation for it to be installed.

If you setup a new VM for this, we suggest the newest Ubuntu LTS release.

If you already have a server or VM with a running docker, just skip this chapter and go on with "Installation".

Install docker on linux

The installation of docker on linux is straightforward. If you Google this topic you will find explanations from the Docker website which invite you to do a manual installation of docker by downloading and installing their actual version. From a technical perspective this is not needed. At least Brinkhaus does not need bleeding edge docker installation. We recommend to just use the docker version which comes from your Linux distribution.

On a typical Ubuntu or Debian you go with

sudo apt update

sudo apt install docker docker-compose

Install docker on Windows

The installation of docker for Windows is described here: https://docs.docker.com/desktop/install/windows-install/

Installation

On a computer with Docker, just choose a target directory which fits for your case, deploy our docker-compose file there and start the app.

Suggestion for quick start for linux

sudo mkdir /var/docker_data
cd /var/docker_data/
sudo wget -O docker-compose.yml https://xwiki.brinkhaus-gmbh.de/bin/download/Product%20support/FileSync/WebHome/docker-compose.yml?rev=1.1
sudo docker login registry.gitlab.com/v2/b3935 -u datastore-dl -p glpat-PRyknAujPzeLoCTPEPfa

sudo docker-compose up -d

You are afterwards able to log in via the web interface on port 80 of the server where you installed FileSync.

Suggestion for quick start for Windows

Place the docker-compose file from here https://xwiki.brinkhaus-gmbh.de/bin/download/Product%20support/FileSync/WebHome/docker-compose.yml?rev=1.1 in a directory of your needs and run "docker-compose up -d".

Variants / hints

You can adapt the docker-compose file to your local needs. The file which we give for a quick start is:

version: "3"

services:
  filesync:
    image: registry.gitlab.com/b3935/ftpmodule/filesync:latest
    container_name: filesync
    restart: always
    volumes:
      - ./data:/app/data

    ports:
      - 80:80

This results in a password-less direct access to a UI on the target server.

We below give an example for enclosing FileSync with Traefik as middleware for adding an easy authentification function:

version: "3"

services:
  traefik:
    image: traefik:v2.2
    command:
      - "--providers.docker"
      - "--entrypoints.web.address=:80"
    ports:
      - "80:80"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
# needed for using a dynamic password, settable from FileSync UI; links data/settings/ to the folder where
# it is described in the "labels" of the filesync container
      - ./data:/var/docker_data/data

  filesync:
    image: registry.gitlab.com/b3935/ftpmodule/filesync:latest
    container_name: filesync
    restart: always
    volumes:
      - ./data:/app/data

# commented out because Traefik creates a protected rout for hisself
#    ports:
#      - 80:80

    labels:
      - "traefik.http.routers.filesync.entrypoints=web"
      - "traefik.http.routers.filesync.rule=Host(`datastore-playground.euprogigant.io`)"
      - "traefik.http.routers.filesync.middlewares=auth"
      - "traefik.http.services.filesync.loadbalancer.server.port=80"
# hard coded password; hash retrievable via "htpasswd -bnBC 10 admin PASSWORD"
      - "traefik.http.middlewares.auth.basicauth.users=admin:$$2y$$10$$2u0mbq4FI.EpN6Gu5O.BpO5Fh8RrXBr.MUT8JyqbYGtNfLn19OhTe" # credentials admin:changeme
# dynamic password, settable from FileSync UI; needs link of data/settings/ in the docker container of Traefik
#      - "traefik.http.middlewares.auth.basicauth.usersfile=/var/docker_data/data/settings/hashedPW.txt"

    

Need support?

If you need support feel free to contact:

Jan Brinkhaus: 0049 179 3939 733