From 9a951098b2932aa0424827f37cab187473ccf841 Mon Sep 17 00:00:00 2001 From: DoDiODev Date: Thu, 23 Jul 2026 11:23:54 +0200 Subject: [PATCH] build(compose): make devlake image registry configurable The docker-compose-dev-*.yml files pull the pre-built devlake-dashboard and devlake-config-ui images through devlake.docker.scarf.sh, the Scarf gateway that provides download analytics for the project. Introduce DEVLAKE_IMAGE_REGISTRY so the registry prefix can be overridden, for example with docker.io to pull directly from Docker Hub. The Scarf gateway stays the default and is written inline in the compose files, so a rendered `docker compose config` is byte-identical when the variable is unset and existing .env files keep working untouched. env.example documents the variable but leaves it commented out on purpose: the services read that file via `env_file`, so an active assignment would also be injected as an environment variable into the running containers. Signed-off-by: DoDiODev --- docker-compose-dev-mysql.yml | 4 ++-- docker-compose-dev-postgresql.yml | 4 ++-- env.example | 9 +++++++++ 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/docker-compose-dev-mysql.yml b/docker-compose-dev-mysql.yml index 56e1f3d1122..a82c3560b4d 100644 --- a/docker-compose-dev-mysql.yml +++ b/docker-compose-dev-mysql.yml @@ -34,7 +34,7 @@ services: --skip-log-bin grafana: - image: devlake.docker.scarf.sh/apache/devlake-dashboard:latest + image: ${DEVLAKE_IMAGE_REGISTRY:-devlake.docker.scarf.sh}/apache/devlake-dashboard:latest build: context: grafana/ ports: @@ -82,7 +82,7 @@ services: - mysql config-ui: - image: devlake.docker.scarf.sh/apache/devlake-config-ui:latest + image: ${DEVLAKE_IMAGE_REGISTRY:-devlake.docker.scarf.sh}/apache/devlake-config-ui:latest build: context: "config-ui" ports: diff --git a/docker-compose-dev-postgresql.yml b/docker-compose-dev-postgresql.yml index b5dbcbb94d8..154dc1ad757 100644 --- a/docker-compose-dev-postgresql.yml +++ b/docker-compose-dev-postgresql.yml @@ -30,7 +30,7 @@ services: TZ: UTC grafana: - image: devlake.docker.scarf.sh/apache/devlake-dashboard:latest + image: ${DEVLAKE_IMAGE_REGISTRY:-devlake.docker.scarf.sh}/apache/devlake-dashboard:latest build: context: grafana/ ports: @@ -78,7 +78,7 @@ services: - postgres config-ui: - image: devlake.docker.scarf.sh/apache/devlake-config-ui:latest + image: ${DEVLAKE_IMAGE_REGISTRY:-devlake.docker.scarf.sh}/apache/devlake-config-ui:latest build: context: "config-ui" ports: diff --git a/env.example b/env.example index b1de659826d..292f127983c 100755 --- a/env.example +++ b/env.example @@ -18,6 +18,15 @@ # Lake core # ############# +# Container image registry/prefix for the pre-built devlake-dashboard and +# devlake-config-ui images used by the docker-compose-dev-*.yml files. +# The default is the Scarf gateway (download analytics for the Apache project) +# and is defined in the compose files themselves, so this entry stays commented +# out: the compose services read this file via `env_file`, and an active +# assignment would also inject the variable into the running containers. +# Uncomment and set it (e.g. docker.io) to pull directly from Docker Hub. +# DEVLAKE_IMAGE_REGISTRY=devlake.docker.scarf.sh + # Lake plugin dir, absolute path or relative path PLUGIN_DIR=bin/plugins REMOTE_PLUGIN_DIR=python/plugins