# Développer une intégration externe avec une image Docker locale

**URL:** <https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488>\
**Category:** Développement\
**Tags:** integration-externe\
**Created:** [Août 8, 2026, 6:10 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488 "2026-08-08T06:10:37Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 8, 2026, 6:10 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/1 "2026-08-08T06:10:37Z")

</div>

Salut.

Je suis en cours de développement d’une intégration externe. Je souhaite tester mon image Docker d’intégration mais dans un premier temps sans vouloir la publier. Le problème avec le mode développeur est qu’il exige que l’image soit publiée sur un dépôt Docker.

Voici l’erreur:

```auto
2026-08-08T05:53:07.708837062Z 2026-08-08T07:53:07+0200 <warn> externalIntegration.install.js:44 (ExternalIntegration.install) Unable to pull image gladys-enphase:0.1.0 Error: (HTTP code 404) unexpected - pull access denied for gladys-enphase, repository does not exist or may require 'docker login' 
2026-08-08T05:53:07.708970278Z at /src/server/node_modules/docker-modem/lib/modem.js:336:17
2026-08-08T05:53:07.709059009Z at IncomingMessage.<anonymous> (/src/server/node_modules/docker-modem/lib/modem.js:363:9)
2026-08-08T05:53:07.709083833Z at IncomingMessage.emit (node:events:531:35)
2026-08-08T05:53:07.709102097Z at endReadableNT (node:internal/streams/readable:1698:12)
2026-08-08T05:53:07.709119958Z at processTicksAndRejections (node:internal/process/task_queues:89:21) {
2026-08-08T05:53:07.709137978Z reason: undefined,
2026-08-08T05:53:07.709154923Z statusCode: 404,
2026-08-08T05:53:07.709256306Z json: null
2026-08-08T05:53:07.709279427Z }

```

Mon image «&nbsp;gladys-enphase:0.1.0&nbsp;» est en local sur ma machine de test. Une idée serait de mettre «&nbsp;./gladys-enphase:0.1.0&nbsp;» pour forcer à utiliser la version locale ou ajouter une option pour ne pas faire l’étape du pull.

Merci.

---

<div class="post-metadata">

**Author:** ![prohand](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/prohand/32/15713_2.png) [@prohand](https://community.gladysassistant.com/u/prohand)\
**Post date:** [Août 8, 2026, 6:21 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/2 "2026-08-08T18:21:09Z")

</div>

Salut,

Tu peux tout à fais utiliser github pour tester et c’est ce que je fais de mon côté. 😉

Simplement pour ta 1er version tu ne mets pas le topic «&nbsp;gladys-assistant-integration&nbsp;» et tu merges tout dans main et tu utilises dans actions «&nbsp;Build en publish image&nbsp;» en selectionnant main.

Une fois que tu as le topic «&nbsp;gladys-assistant-integration&nbsp;» en place avec ta 1er version en place tu ne merge pas dans main et tu utilises dans actions «&nbsp;Build en publish image&nbsp;» en selectionnant bien la branche sur laquel tu travail.

Une fois que c’est fini tu aura les instructions pour tester dans les 2 cas.

Si ce n’est pas clair hésite pas 😉

---

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 9, 2026, 6:12 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/3 "2026-08-09T06:12:17Z")

</div>

Ben c’est justement ce que je veux éviter c’est de créer un projet Github juste pour cela alors que je veux utiliser Gitlab au final.

---

<div class="post-metadata">

**Author:** ![prohand](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/prohand/32/15713_2.png) [@prohand](https://community.gladysassistant.com/u/prohand)\
**Post date:** [Août 9, 2026, 6:40 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/4 "2026-08-09T06:40:53Z")

</div>

Ah ok je laisserai @pierre-gilles répondre alors 😉

---

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 10, 2026, 3:09 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/5 "2026-08-10T15:09:09Z")

</div>

En attendant j’ai créé un dépôt sur mon compte GitLab qui fait office de Docker registry. Je build en local et je push sur ce registry pour le récupérer au final sur Gladys.

---

<div class="post-metadata">

**Author:** ![pierre-gilles](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/pierre-gilles/32/5886_2.png) [@pierre-gilles](https://community.gladysassistant.com/u/pierre-gilles)\
**Post date:** [Août 10, 2026, 3:36 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/6 "2026-08-10T15:36:38Z")

</div>

Comme répondu dans l’autre sujet, je ne prévois pas de supporter d’autres plateformes que Github :

> [@Intégration externe sur GitLab et Codeberg](https://community.gladysassistant.com/t/integration-externe-sur-gitlab-et-codeberg/10490/2):
>
> Salut @ArMour85, Merci pour la demande. Je vais t’expliquer franchement pourquoi ça ne se fera pas, plutôt que de laisser le sujet traîner. Le système d’intégrations externes ne se contente pas de pointer vers un dépôt, il repose sur l’écosystème GitHub à deux endroits : la découverte : je scanne GitHub via un topic pour trouver automatiquement les intégrations publiées, ce qui évite tout processus de validation manuelle de ma part la publication : le template fournit des GitHub Actions déjà…

---

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 10, 2026, 3:38 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/7 "2026-08-10T15:38:56Z")

</div>

Oui mais ma demande c’est de pouvoir utiliser une image Docker déjà sur le PC qui fait tourner Gladys. Cela me permet de build en local l’image Docker et de le tester tout de suite sans passer par de la CI sur GitHub.

---

<div class="post-metadata">

**Author:** ![pierre-gilles](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/pierre-gilles/32/5886_2.png) [@pierre-gilles](https://community.gladysassistant.com/u/pierre-gilles)\
**Post date:** [Août 10, 2026, 7:43 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/8 "2026-08-10T19:43:43Z")

</div>

Effectivement, j’ai fais une PR :

> <https://github.com/GladysAssistant/Gladys/pull/2841>
>
> \### Description
> 
> The developer install mode of external integrations (developer …mode in the UI) always pulled the Docker image, and a failed pull was fatal. An image built locally with \`docker build\` — which exists in no registry — could therefore neither be installed nor updated: the dev loop required pushing every build to a registry first.
> 
> Install and update now fall back on the image already present locally when the pull fails:
> 
> \- New \`system.imageExists(imageName)\`: checks the local presence of an image via \`dockerode.getImage().inspect()\` (404 → \`false\`, other daemon errors are rethrown).
> \- New \`externalIntegration.ensureImage(image)\`: tries \`system.pull()\` first — the registry stays the source of truth whenever it answers, so a mutable tag is still refreshed on every install/update — and only when the pull fails accepts an image already present locally. When the image is neither pullable nor local, the existing explicit \`UNABLE\_TO\_PULL\_IMAGE\` error is raised unchanged.
> \- \`install\` (main image + sub-container images) and \`update\` (candidate resolution + sub-container images) go through \`ensureImage\`. For a dev install this enables the local loop: rebuild the image with \`docker build\`, hit "force update", the new local build is used and its manifest is refreshed from the image labels.
> \- The dev-mode hint in the UI (en/fr/de) now says the image can be built locally without a registry.
> 
> The locally built image is protected from the image sweeps like any other: \`system.pull\` stamps the pull time even on failure (recently-pulled protection during the install window), and once the \`t\_service\` row references it, \`getImagesInUse\` keeps it out of every cleanup.
> 
> Tests: new \`system.imageExists\` suite, install from a local-only image (main + sub-container), update of a dev install from a locally rebuilt image, and the failure paths (image neither pullable nor local, local presence check itself failing).
> 
> \### Checklist
> 
> \- \[x\] Tests pass: \`server\` mocha suites for \`external-integration\` and \`system\` pass locally (the \`store\` tests fail in this sandbox for a pre-existing reason: outbound HTTP is proxied and \`nock\`-based tests receive 405s — unrelated to this change)
> \- \[x\] Linter and prettier pass on both front and server for the changed files
> \- \[x\] No undocumented breaking change
> 
> \---
> \_Generated by \[Claude Code\](https://claude.ai/code/session\_0117785yHMXBjTVUYPhDdRBt)\_
> 
> 
> \## Summary by CodeRabbit
> 
> \* \*\*New Features\*\*
> \* Developer-mode integrations can use Docker images built locally without requiring a registry.
> \* Local images are supported for primary integrations and sub-containers during installation and updates.
> 
> \* \*\*Bug Fixes\*\*
> \* Improved image availability handling and error reporting when images cannot be pulled or found.
> \* Store installations and updates continue to require images from a registry.
> 
> \* \*\*Documentation\*\*
> \* Updated English, German, and French instructions to explain local Docker image builds.

Tu peux tester en local sur la branche et me dire si ça marche bien chez toi avec ça ? 🙂

---

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 10, 2026, 9:38 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/9 "2026-08-10T21:38:44Z")

</div>

A super merci. Je le fais dès que je peux.

---

<div class="post-metadata">

**Author:** ![ArMour85](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/armour85/32/7457_2.png) [@ArMour85](https://community.gladysassistant.com/u/ArMour85)\
**Post date:** [Août 11, 2026, 7:34 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/10 "2026-08-11T07:34:29Z")

</div>

C’est bon pour moi ça fonctionne. Merci pour ta réactivité.

---

<div class="post-metadata">

**Author:** ![pierre-gilles](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/pierre-gilles/32/5886_2.png) [@pierre-gilles](https://community.gladysassistant.com/u/pierre-gilles)\
**Post date:** [Août 11, 2026, 3:42 UTC](https://community.gladysassistant.com/t/developper-une-integration-externe-avec-une-image-docker-locale/10488/11 "2026-08-11T15:42:48Z")

</div>

Merci d’avoir testé, c’est mergé sur master 🙂
