Images Exemples d'utilisation - pifou25/docker-jeedom GitHub Wiki
Le script ./install.sh download le Jeedom officiel, il faut donc modifier ce script après download (à défaut de le modifier de manière pérenne au risque de push une modif non voulue dans le core)...
- Démarrer Debian dans un container docker (si besoin)
- maj et install du package wget (si besoin)
- download le script install.sh
- sed remplace l'URL de jeedom par la mienne
- sed pour le rep jeedom-core-* au lieu de core-
- Ajout du flag exécution
- installation de Jeedom
docker run -ti --rm -p 80:80 debian:11-slim bash
apt update && apt install -y wget
wget https://raw.githubusercontent.com/pifou25/jeedom-core/beta/install/install.sh
sed -i -e "s%github.com/jeedom/core%github.com/pifou25/jeedom-core%g" install.sh
sed -i -e "s%/root/core-%/root/jeedom-core-%g" install.sh
chmod +x install.sh
./install.sh -v beta
utilisons l'image officielle
$ docker run --rm --interactive --tty \
--volume $PWD:/app \
composer <command>
exemple pour l'install:
docker run --rm -ti -v $PWD:/app composer install
j'utilise toujours le répertoire courant $PWD comme source du projet, et je dirige le port 80 du container vers le 8080 de l'hôte. Voir l'aide sur la page officielle de l'image php
docker run --rm -ti -v $PWD:/var/www/html -p 8080:80 php:7.3-apache-buster
Pour Jeedom il faudra faire un fichier Dockerfile spécifique pour ajouter des extensions php nécessaires, puis builder et lancer la commande docker run sur cette nouvelle image ==> image jeedom:light (allégé car ne contient que apache-php et les extensions nécessaires - manque donc tous les autres process: cron atd mysql à minima, fail2ban...)
Ou alors, la pensée inverse d'un heavy-fat container, the jeedom:full qui contient la full install, standalone, tous les process & démons requis dans 1 seul container, gérés par supervisor.
3è conteneur utile ==> jeedom:xdebug = jeedom:light augmenté avec l'extention php pour le déboggage php pas-à-pas compatible Visual Studio (et autres IDE)
Voir l'image officielle ou bien la version de 'linuxserver' pour RPI
docker run -d --network nginx_default --name mariadb -e MARIADB_ROOT_PASSWORD=admin -e MARIADB_DATABASE=jeedom -e MARIADB_USER=jeedom -e MARIADB_PASSWORD=jeedom -d mariadb
Utilisation du script python traduitjdm pour traduire les textes php et js et créer un fichier de langues au format json / jeedom :
git clone https://github.com/jeedom/core.git jeedom
git clone https://github.com/pifou25/jeedom-lgthinq-plugin.git -b dev jeedom/plugins/lgthinq
git clone https://github.com/ktn001/traduitjdm.git
docker run --rm -ti -v $PWD/jeedom:/var/www/html -v $PWD/traduitjdm:/app -w /app/bin --name traduitjdm python:3 python traduitjdm lgthinq
docker run -d -p 8080:8080 -p 8443:443 -v /userdata:/opt/domoticz/userdata -e TZ=Europe/Paris --name=domoticz domoticz/domoticz
Ajouter les devices identifiés via lsusb
avec l'argument: --device=<device_id>
see https://hub.docker.com/r/domoticz/domoticz
docker run -d --name homeassistant --privileged --restart=unless-stopped -e TZ=Europe/Paris -v /homeassistant:/config --network=host homeassistant/home-assistant