Installation dans Docker

La procédure suivante s’adresse aux utilisateurs maitrisant les environnements Docker.

Important

Les instances Jeedom sous Docker ne sont pas prises en charge par le support officiel.

Docker installation

Docker est disponible sur toutes les distributions récentes. To install it on a distribution

Installing a Jeedom image

Image installation :

docker pull jeedom/jeedom:latest

Puis lancez la :

sudo docker run --name jeedom-server --privileged -v /opt/jeedom/www:/var/www/html -v /opt/jeedom/db:/var/lib/mysql -p 80:80 -d jeedom/jeedom:latest

With :

INFORMATION

Avec l’option -d (detach), Docker vous rend immédiatement la main mais installe en tâche de fond. It is possible to follow the logs with the command docker logs jeedom-server -f (option f = follow)

Then you need to install Jeedom by going to : IP_DOCKER:80

INFORMATION

You can see the dockers turning docker ps to stop your container, jeedom-server for example, you just have to do docker stop jeedom-server, to revive it docker start jeedom-server

Docker compose

You too can install jeedom using docker compose :

En mode 1 service

services:
  jeedom:
    image: jeedom/jeedom:latest
    volumes:
      - http:/var/www/html
      - db:/var/lib/mysql
    tmpfs:
      - /tmp/jeedom
    ports:
      - 40080:80
    restart: always
    network_mode: bridge
    healthcheck:
      test: ["CMD", "curl", "-fs", "-S", "--max-time", "2", "http://localhost:80"]
      interval: 30s
      timeout: 10s
      retries: 5
volumes:
  db:
  http:

En mode 2 services (experimental)

services:
  jeedom_db:
    image: mariadb:latest
    container_name: jeedom_db
    command:
      - "--default-authentication-plugin=mysql_native_password"
      - "--skip-name-resolve"
      - "--key_buffer_size=16M"
      - "--thread_cache_size=16"
      - "--tmp_table_size=48M"
      - "--max_heap_table_size=48M"
      - "--query_cache_type=1"
      - "--query_cache_size=32M"
      - "--query_cache_limit=2M"
      - "--query_cache_min_res_unit=3K"
      - "--innodb_flush_method=O_DIRECT"
      - "--innodb_flush_log_at_trx_commit=2"
      - "--innodb_log_file_size=32M"
      - "--innodb_large_prefix=on"
      - "--connect_timeout=600"
      - "--wait_timeout=600"
      - "--interactive_timeout=600"
    volumes:
      - db:/var/lib/mysql
    restart: always
    environment:
      - MYSQL_ROOT_PASSWORD=TODO
      - MYSQL_DATABASE=jeedom
      - MYSQL_USER=jeedom
      - MYSQL_PASSWORD=TODO
    expose:
      - 3306
  jeedom_http:
    image: jeedom/jeedom:4.4-http-bookworm
    container_name: jeedom_http
    volumes:
      - http:/var/www/html
    tmpfs:
      - /tmp/jeedom
    ports:
      - 52080:80
    restart: always
    environment:
      - DB_HOST=jeedom_db
      - DB_USERNAME=jeedom
      - DB_PASSWORD=TODO
      - DB_NAME=jeedom
    healthcheck:
      test: ["CMD", "curl", "-fs", "-S", "--max-time", "2", "http://localhost:80"]
      interval: 30s
      timeout: 10s
      retries: 5
    depends_on:
      - jeedom_db
volumes:
  db:
  http:

INFORMATION

Do not forget to complete the TODO with the desired passwords

It is possible to specify the Apache listening port with the environment variable APACHE_PORT, be careful to update the healthcheck with the new port. Please note that this is only possible from Jeedom 4.5

List of available images

The full list is available at Docker Hub

Première connexion

Consulter la documentation relative à la Première connexion pour accéder à l’interface Jeedom suite à l’installation.

Nous utilisons des cookies pour vous garantir la meilleure expérience sur notre site web. Si vous continuez à utiliser ce site, nous supposerons que vous en êtes satisfait.