Dieser Artikel ist aufgrund seiner technischen Natur nur in Englisch verfügbar.
Haiilo is only available with docker. Docker is a tool for container based micro services.
https://www.docker.com/what-docker
A Container stands for virtualization of a single application/service, for example a Webserver like Apache and a MySQL Database.
Docker provides several images to run predefined services. You are also able to create your own images.
We are using the official docker-compose tool to orchestrate a bunch of services (database, application server, frontend server, message queue, elasticsearch server and so on) which all are needed for Haiilo.
If you want a more detailed view of how Haiilo works, check your our Technical OnBoarding Guide.Prerequisites
- Port 80 and 443 for HTTP/S connections
- Port 8083 for Haiilo backup REST API
- Port 5601 for Kibana to access the Haiilo server logs
- Port 5602 for Grafana to access the metrics stack (optional)
Server software Requirements
- docker >= 18.03.2
- docker-compose >= 1.26.0
- bash
- unzip
Haiilo is a Java based application, available in docker. Why docker?
The containers can be installed and run easily by using the command-line or Docker supporting administration tools. While installation is simple, updating Haiilo with Docker is even simpler because containers can be dropped and re-initiated with a newer version in a matter of seconds.
Our Haiilo composition of many different containers is available as a Docker composition and can be run wherever Docker-Compose is available. Currently this is Linux and Mac OS but we only recommend Linux distributions.
We made good experiences with Ubuntu, Debian, RedHat, SLES and CentOS.
This is a guide written for Ubuntu distributions.https://www.ubuntu.com/download/server
Server hardware requirements
Client browser requirements
*IE11 is supported but not recommended. For a great user experience use a modern browser.
**The support of versions of Microsoft Edge older than v80 is deprecated and will be removed in future releases
Install Docker
To get an overview of the supported Linux distributions and how to install docker, follow the official installation instructions: https://docs.docker.com/install/
Installing Docker on Ubuntu 18.04 LTS:\nsudo apt install docker.io
Install Docker Compose
curl -L --fail https://github.com/docker/compose/releases/download/1.26.0/run.sh > /usr/local/bin/docker-compose && \\\nchmod +x /usr/local/bin/docker-compose && \\\ndocker-compose --version\n
Prepare the host system
sudo adduser coyo
sudo adduser coyo sudo
sudo -i -u coyo
cd /home/coyo
mkdir coyo-data
(To check available COYO versions check https://download.coyoapp.com/release/onpremises)\n
wget https://download.coyoapp.com/release/onpremises/coyo4_<coyo-version>.zip\nunzip coyo4_<coyo-version>.zip`\n
-rw-r--r-- 1 root root 6753 Nov 26 16:38 coyo4_18.10.3-RELEASE.zip\n-rw-r--r-- 1 root root 170 Nov 26 16:38 coyo-backend.properties\n-rw-r--r-- 1 root root 89 Nov 26 16:38 coyo-backup.properties\n-rw-r--r-- 1 root root 87 Nov 26 16:38 coyo-push.properties\n-rwxr-xr-x 1 root root 11419 Nov 26 16:38 docker-compose.yml\n-rw-r--r-- 1 root root 3625 Nov 26 16:38 .env\n-rw-r--r-- 1 root root 1323 Nov 26 16:38 README.md\n-rwxr-xr-x 1 root root 565 Nov 26 16:38 start-advanced.sh\n-rwxr-xr-x 1 root root 1162 Nov 26 16:38 start.sh\n-rwxr-xr-x 1 root root 55 Nov 26 16:38 stop.sh
Configure the environment variables for Docker
URL configuration
(Make sure domains are configured correctly)\n
COYO_BACKEND_URL=test.coyoapp.com
COYO_FRONTEND_URL=test.coyoapp.com
Environment profile
COYO_PROFILE=prod
Management user
COYO_MANAGEMENT_USER=admin
COYO_MANAGEMENT_PASSWORD=coyo4admin
Database
COYO_DB_NAME=dbname
COYO_DB_USER=dbuser
COYO_DB_PASSWORD=dbpassword
File database
COYO_FILE_PORT=27017
COYO_FILE_DATABASE=coyo-files
Data location
COYO_DATA_STORAGE=./coyo-data
Outgoing email configuration
COYO_MAIL_FROM=Company <mailman@domain.tld>
COYO_MAIL_HOST=smtp.domain.tld
COYO_MAIL_USERNAME=smtp-user
COYO_MAIL_PASSWORD=smtp-password
COYO_MAIL_PORT=25
COYO_MAIL_PROTOCOL=smtp
SSL Certificate
COYO_CERT_FILE=./cert.pem
Check out this article for more information about the SSL certificate file.
Backup task
Configure the interval to run the backup and where it should be stored. The BACKUP_CRON property takes a crontab line as value. The pattern of those crontabs is a list of six single space-separated fields: second, minute, hour, day, month, weekday. Month and weekday names can be given as the first three letters of the English names.
BACKUP_CRON=0 30 3 * * *
BACKUP_PATH=/srv/backup
Example patterns:
-
0 0 * * * *
= the top of every hour of every day. -
*/10 * * * * *
= every ten seconds. -
0 0 8-10 * * *
= 8, 9 and 10 o'clock of every day. -
0 0 6,19 * * *
= 6:00 AM and 7:00 PM every day. -
0 30 3 * * *
= every day at 3:30 AM. -
0 0/30 8-10 * * *
= 8:00, 8:30, 9:00, 9:30, 10:00 and 10:30 every day. -
0 0 9-17 * * MON-FRI
= on the hour nine-to-five weekdays -
0 0 0 25 12 ?
= every Christmas Day at midnight
Session timeout
An example: As a user, you get logged out after one month of inactivity.
(Only whole numbers are allowed.)
COYO_SESSION_REMEMBER_TIMEOUT=2674800
Elasticsearch configuration
We suggest 12.5% of your RAM for ES_HEAP_SIZE and 6.25% for ES_LOGS_HEAP_SIZE.
(m/M for Megabytes or g/G for Gigabytes)
The ES_LOGS_KEEP_DAYS defines how long log entries get stored in days.
ES_HEAP_SIZE=2g
ES_LOGS_HEAP_SIZE=1g
ES_LOGS_KEEP_DAYS=84
Java VM memory configuration
(m/M for Megabytes or g/G for Gigabytes)
COYO_JAVA_OPTS=-Xmx4g -server
COYO_PUSH_JAVA_OPTS=-Xmx1g -server
COYO_BACKUP_JAVA_OPTS=-Xmx1g -server
Database configuration
With these parameters, you can configure the Postgres database.
The two max connections parameters set the maximum number of connections in general and the number of active connections that can be allocated from this pool as well.
The synchronous commit indicates the transaction strategy.
The shared buffers is the max amount of data temporarily stored in the RAM for faster access.
We suggest 6.25% of your RAM but less is also possible.
The working memory is used for large queries and sorting within the database.
For single-host environments, you don't have to change our default values.
COYO_DB_MAX_ACTIVE_CONNECTIONS=100
COYO_DB_MAX_CONNECTIONS=400
COYO_DB_SYNCHRONOUS_COMMIT=false
COYO_DB_SHARED_BUFFERS=1024MB
COYO_DB_WORK_MEM=32MB
Server configuration
Max. threads define the max amount of worker threads.
With Backend cluster, you have multiple, clustered backend instances. This should only be true for very large and highly available instances.
COYO_SERVER_MAX_THREADS=200For single-host environments please add the following line to your .env-file\n
COYO_BACKEND_CLUSTER=false
COYO_SINGLE_BACKEND=true
HTTP Security Headers
Enable HTTP Content-Security-Policy Header. The Content-Security-Policy HTTP response header helps you reduce XSS risks on modern browsers by declaring what dynamic resources are allowed to load via an HTTP Header. Disabled, if blank (default).
Enable HTTP Transport Security Header to include subdomains.
COYO_HTTP_CONTENT_SECURITY_POLICY=
COYO_HTTP_TRANSPORT_SECURITY_INCLUDE_SUBDOMAINS=true
Push notification service
If you don't have such a service account .json but want to use push notifications, please contact our Support team. We can provide you with one.
The thread limit limits the number of parallel executed push notifications.
COYO_PUSH_ACCOUNT_JSON=
COYO_PUSH_THREAD_LIMIT=10
ActiveMQ configuration
The multiplier is used to calculate the effective read heart-beat timeout.
The MAX_ and MIN_MEMORY parameters define the initial and max memory in MB that ActiveMQ. For max. we suggest 9.6% of your RAM.
The log level of the ActiveMQ is defined as INFO, WARN, or ERROR.
For single-host environments you don't have to change our default values except for MAX_MEMORY.
COYO_ACTIVEMQ_MAX_CONNECTIONS=100000
COYO_ACTIVEMQ_HB_GRACE_PERIOD_MULTIPLIER=2.5
COYO_ACTIVEMQ_MIN_MEMORY=512
COYO_ACTIVEMQ_MAX_MEMORY=1536
COYO_ACTIVEMQ_LOGLEVEL=WARN
Authorization Key
Since version 21.x Haiilo also requires a JSON Web Token to authorize users to the services. This token must be at least 256 bits (32 bytes) long and can be created using an online hash generator, for example.
COYO_AUTHORIZATION_KEY=
Start Haiilo
To start Haiilo without the optional metrics stack run:
sudo ./start.sh
sudo ./start-advanced.sh
sudo docker ps
(Make sure to replace COYO_DATA_STORAGE with the value defined in your .env file)
tail -f COYO_DATA_STORAGE/backend/logs/coyo-backend.log
sudo ./stop.sh
What now?
For you, as a system administrator, we suggest having a look at our Guides to integrate a user directory and to set up an authentication provider.
Also, you can check out our Update Guide to be ready for our next release or our Backup Guide.