feat: update Dockerfiles and configuration for TLS support across multiple modules

Signed-off-by: d9pouces <github@19pouces.net>
This commit is contained in:
d9pouces
2026-09-05 22:23:34 +02:00
parent fc41dfaa07
commit a5a36fc7cd
20 changed files with 441 additions and 132 deletions
+2 -10
View File
@@ -1,5 +1,4 @@
import json
import subprocess
from unittest.mock import MagicMock
from typer.testing import CliRunner
@@ -66,14 +65,7 @@ def test_apply_skips_irrelevant_modules(tmp_path, caplog) -> None:
assert "skipping module python" in caplog.text
def test_apply_runs_relevant_module(tmp_path, monkeypatch) -> None:
mock_run = MagicMock(
return_value=subprocess.CompletedProcess(
args=[], returncode=0, stdout="", stderr=""
)
)
monkeypatch.setattr("id_configurator.modules.certificates.subprocess.run", mock_run)
def test_apply_runs_relevant_module(tmp_path) -> None:
config_path = write_config(tmp_path, CONFIG_WITH_CERT)
dst = tmp_path / "dst"
result = runner.invoke(
@@ -82,7 +74,7 @@ def test_apply_runs_relevant_module(tmp_path, monkeypatch) -> None:
assert result.exit_code == 0
assert (dst / "usr/local/share/ca-certificates/my-ca.crt").read_bytes() == b"fake"
mock_run.assert_called_once()
assert (dst / "etc/ssl/certs/ca-certificates.crt").read_bytes() == b"fake\n"
def test_main_default_name_calls_app(monkeypatch) -> None: