From cbc80ca081b7ea0463a6ebf420b0b27ba0cc1106 Mon Sep 17 00:00:00 2001 From: Nathan Tenney Date: Tue, 13 Jan 2026 14:46:13 -0800 Subject: [PATCH] Changes to make the generation of SSL certs optional based on the protocol of the bind address --- core/bootstart.sh | 2 ++ core/setup-platform.py | 3 +++ 2 files changed, 5 insertions(+) diff --git a/core/bootstart.sh b/core/bootstart.sh index 58faa80..1eac149 100755 --- a/core/bootstart.sh +++ b/core/bootstart.sh @@ -6,6 +6,8 @@ if [[ -z /startup/setup-platform.py ]]; then exit 1 fi +export PYTHONPATH=$PYTHONPATH:$VOLTTRON_ROOT + echo "Before platform setup, print environment." printenv diff --git a/core/setup-platform.py b/core/setup-platform.py index 733d613..80bfa88 100755 --- a/core/setup-platform.py +++ b/core/setup-platform.py @@ -94,6 +94,9 @@ def _create_platform_config_file(platform_cfg, cfg_path): def _create_certs(cfg_path, platform_cfg): + if not platform_cfg.get("bind-web-address", "").startswith("https://"): + print("Web address is not set to use SSL. Skipping certificate creation.") + return print("Creating CA Certificate...") # We need to import Certs here because we Certs depends on zmq, which only gets installed after _install_required_deps() is executed. # If we put this import statement at the top of the module, we will run into an import error because zmq gets