From 8c703a8a045e6ed1c9c412f23363a8a50ebe34cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Sun, 14 Sep 2025 20:03:27 -0300 Subject: [PATCH 1/6] bootstrap: Add missing GIT_DESCRIBE_TAGS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- bootstrap/Dockerfile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/bootstrap/Dockerfile b/bootstrap/Dockerfile index 5d733084c3..1500e9f9ae 100644 --- a/bootstrap/Dockerfile +++ b/bootstrap/Dockerfile @@ -1,5 +1,19 @@ FROM python:3.11.7-slim-bullseye +# Ensure that the git describe exists and also is in valid format as well +# The format can be invalid if someone is build BlueOS without a tag as reference +ARG GIT_DESCRIBE_TAGS +ENV GIT_DESCRIBE_TAGS=${GIT_DESCRIBE_TAGS:-0.0.0-0-g00000000} +RUN <<-EOF +set -e + + if [[ ! $GIT_DESCRIBE_TAGS =~ -[0-9]+-g[a-f0-9]{8}$ ]]; then + echo "Invalid format: $GIT_DESCRIBE_TAGS (E.g: --g)" + exit 1 + fi + +EOF + COPY startup.json.default bootstrap/ /bootstrap/ COPY main.py / COPY pip.conf /etc/ From 5c745b1fae7a0c37ffd882909ece2309ea1fced9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Sun, 14 Sep 2025 20:03:44 -0300 Subject: [PATCH 2/6] bootstrap: README: Fix docker name MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- bootstrap/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bootstrap/README.md b/bootstrap/README.md index 8dc4aa0bfc..0f33b7d1bb 100644 --- a/bootstrap/README.md +++ b/bootstrap/README.md @@ -18,7 +18,7 @@ docker build . --tag bluerobotics/bootstrap:master Everytime it is launched, it will load the startup settings, wait until the core container is not running, and re-create and re-launch it. ```bash -docker run -it -v /var/run/docker.sock:/var/run/docker.sock -v /config:/config bluerobotics/bootstrap:master +docker run -it -v /var/run/docker.sock:/var/run/docker.sock -v /config:/config bluerobotics/blueos-bootstrap:master ``` This will automatically populate /config if there is no valid config file in there, fetch if necessary, and then launch BlueOS. From 0fd13197544e1b49491d936bbdb42d1069f76f97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Sun, 14 Sep 2025 20:03:55 -0300 Subject: [PATCH 3/6] bootstrap: Fix example command MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- bootstrap/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bootstrap/main.py b/bootstrap/main.py index 43c4bf3f92..afe063a870 100755 --- a/bootstrap/main.py +++ b/bootstrap/main.py @@ -19,8 +19,8 @@ "docker run -it -v /var/run/docker.sock:/var/run/docker.sock" " -v $HOME/.config/blueos:" " -v /var/logs/blueos:/var/logs/blueos" - "/root/.config/blueos -e BLUEOS_CONFIG_PATH=$HOME/.config/blueos" - "bluerobotics/blueos-bootstrap:master" + " /root/.config/blueos -e BLUEOS_CONFIG_PATH=$HOME/.config/blueos" + " bluerobotics/blueos-bootstrap:master" ) sys.exit(1) From a677c070382f499584b6d1821d59fb8b6690e76a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Sun, 14 Sep 2025 20:10:37 -0300 Subject: [PATCH 4/6] bootstrap: Fix bind command MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- bootstrap/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bootstrap/main.py b/bootstrap/main.py index afe063a870..6a01a056a0 100755 --- a/bootstrap/main.py +++ b/bootstrap/main.py @@ -17,7 +17,7 @@ logger.info("Example docker command line:") logger.info( "docker run -it -v /var/run/docker.sock:/var/run/docker.sock" - " -v $HOME/.config/blueos:" + " -v $HOME/.config/blueos:/root/.config/blueos" " -v /var/logs/blueos:/var/logs/blueos" " /root/.config/blueos -e BLUEOS_CONFIG_PATH=$HOME/.config/blueos" " bluerobotics/blueos-bootstrap:master" From 92561fb4446b0d08219e1aadfe3231c855b35324 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Sun, 14 Sep 2025 20:19:37 -0300 Subject: [PATCH 5/6] bootstrap: Add network=host in example command line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- bootstrap/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bootstrap/main.py b/bootstrap/main.py index 6a01a056a0..5701532c99 100755 --- a/bootstrap/main.py +++ b/bootstrap/main.py @@ -16,7 +16,8 @@ logger.info("Please supply the host path for the config files as the BLUEOS_CONFIG_PATH environment variable.") logger.info("Example docker command line:") logger.info( - "docker run -it -v /var/run/docker.sock:/var/run/docker.sock" + "docker run -it --network=host" + " -v /var/run/docker.sock:/var/run/docker.sock" " -v $HOME/.config/blueos:/root/.config/blueos" " -v /var/logs/blueos:/var/logs/blueos" " /root/.config/blueos -e BLUEOS_CONFIG_PATH=$HOME/.config/blueos" From 6325ac0af80440716b176ea2c5ad17afa41eaf73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Tue, 23 Sep 2025 18:23:44 -0300 Subject: [PATCH 6/6] core: Dockerfile: Remove check for GIT_DESCRIBE_TAGS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It's set by default Signed-off-by: Patrick José Pereira --- core/Dockerfile | 6 ------ 1 file changed, 6 deletions(-) diff --git a/core/Dockerfile b/core/Dockerfile index 223decbd98..6347f0af6a 100644 --- a/core/Dockerfile +++ b/core/Dockerfile @@ -73,12 +73,6 @@ ENV GIT_DESCRIBE_TAGS=${GIT_DESCRIBE_TAGS:-0.0.0-0-g00000000} RUN <<-EOF set -e - if [ -z "$GIT_DESCRIBE_TAGS" ]; then - echo "GIT_DESCRIBE_TAGS argument not provided." - echo "Use: --build-arg GIT_DESCRIBE_TAGS=\$(git describe --tags --long --always)" - exit 1 - fi - if [[ ! $GIT_DESCRIBE_TAGS =~ -[0-9]+-g[a-f0-9]{8}$ ]]; then echo "Invalid format: $GIT_DESCRIBE_TAGS (E.g: --g)" exit 1