lab7: локальная PKI (public-ca для ingress, internal-ca для сервисов), HTTPS ingress на 8443, без открытого 8080

This commit is contained in:
Alexey Bodanyuk
2026-11-27 16:09:46 +03:00
parent 6435b6a1c5
commit 7c43d31dc7
5 changed files with 210 additions and 16 deletions
+11
View File
@@ -0,0 +1,11 @@
# Run a long command as a separate Windows process that survives the calling shell/session.
# powershell -File scripts/bg.ps1 -Log evidence/run.log -Cmd "docker compose up -d --build --wait"
# The command runs in Git Bash (same syntax as the Makefile/hooks); the exit code is the last
# line of the log ("exit=N"). Nothing secret is printed by the commands used with it.
param([Parameter(Mandatory)][string]$Log, [Parameter(Mandatory)][string]$Cmd)
$bash = Join-Path $env:ProgramFiles "Git\bin\bash.exe"
$root = Split-Path -Parent $PSScriptRoot
$logPath = if ([IO.Path]::IsPathRooted($Log)) { $Log } else { Join-Path $root $Log }
New-Item -ItemType Directory -Force (Split-Path -Parent $logPath) | Out-Null
$inner = "cd '$($root -replace '\\','/')' && export PYTHONUTF8=1 && { $Cmd ; } > '$($logPath -replace '\\','/')' 2>&1; echo exit=`$? >> '$($logPath -replace '\\','/')'"
Start-Process -FilePath $bash -ArgumentList @('-lc', "`"$inner`"") -WindowStyle Hidden