docs: fix stale references across all documentation

- ARCHITECTURE.md: fix WinRM subnet (192.168.1179), VM box shows VS 2026/Python 3.13/unzip+python build instead of .NET SDK 8/git clone/dotnet build
- BEST-PRACTICES.md: fix VMnet11/192.168.11  VMnet8 NAT/192.168.79
- CI-FLOW.md: Step 3 workflow YAML updated to actual Invoke-CIJob.ps1 params (Submodules, BuildCommand, GuestArtifactSource); note that -VMIPAddress is auto-detected
- OPTIMIZATION.md: BaseClean tier updated to VS BuildTools 2026, .NET SDK 10.0.203, Python 3.13.3
- gitea/workflow-example.yml: remove BUILD_VM_IP (auto-detected), replace -VMIPAddress/-Configuration with -Submodules/-BuildCommand/-GuestArtifactSource
This commit is contained in:
Simone
2026-05-08 23:36:57 +02:00
parent dd238121b3
commit 6ba8cca70a
5 changed files with 40 additions and 36 deletions
+7 -6
View File
@@ -53,7 +53,7 @@ The runner host **never executes build tools directly**. Its only role is orches
│ │ ├── Clone_Job_002.vmx │ │
│ │ └── Clone_Job_003.vmx │ │
│ └───────────────────────────────────────────────────────────────────┘ │
│ │ WinRM :5985 (192.168.11.0/24)
│ │ WinRM :5985 (192.168.79.0/24 NAT)
└──────────────────────────────────┼──────────────────────────────────────┘
┌────────────────────────┼──────────────────────────┐
@@ -64,13 +64,14 @@ The runner host **never executes build tools directly**. Its only role is orches
│ (ephemeral) │ │ (ephemeral) │ │ (ephemeral) │
│ │ │ │ │ │
│ VS Build Tools │ │ VS Build Tools │ │ VS Build Tools │
.NET SDK 8 │ │ .NET SDK 8 │ │ .NET SDK 8
Git │ │ Git │ │ Git
2026 (v145) │ │ 2026 (v145) │ │ 2026 (v145)
.NET SDK 10 │ │ .NET SDK 10 │ │ .NET SDK 10
│ Python 3.13.3 │ │ Python 3.13.3 │ │ Python 3.13.3 │
│ WinRM enabled │ │ WinRM enabled │ │ WinRM enabled │
│ │ │ │ │ │
│ > git clone │ │ > git clone │ │ > git clone
│ > dotnet build │ │ > dotnet build │ │ > dotnet build │
│ > artifacts │ │ > artifacts │ │ > artifacts
│ > unzip src │ │ > unzip src │ │ > unzip src
│ > python build │ │ > python build │ │ > python build │
│ > dist/ │ │ > dist/ │ │ > dist/
│ │ │ │ │ │
│ [DESTROYED] │ │ [DESTROYED] │ │ [DESTROYED] │
└──────────────────┘ └──────────────────┘ └──────────────────┘
+1 -1
View File
@@ -35,7 +35,7 @@ $cred = Get-StoredCredential -Target 'BuildVMGuest'
### Current setup (HTTP / port 5985)
Acceptable for an **isolated lab network** where:
- Build VMs are on a dedicated host-only VMware network (192.168.11.0/24 — VMnet11 dedicated CI)
- Build VMs sono su VMnet8 NAT (192.168.79.0/24)raggiungibili dall'host, internet via NAT
- No external traffic reaches port 5985
- Credentials are managed via Windows Credential Manager
+14 -6
View File
@@ -54,16 +54,24 @@ The workflow YAML defines steps that run as PowerShell commands **on the host**.
The first substantive step calls `Invoke-CIJob.ps1`:
```yaml
- name: Build in ephemeral VM
- name: Run CI Job
shell: pwsh
run: |
.\scripts\Invoke-CIJob.ps1 `
-JobId "${{ github.run_id }}" `
-RepoUrl "${{ env.GITEA_REPO_URL }}" `
-Branch "${{ github.ref_name }}" `
-Commit "${{ github.sha }}"
& 'N:\Code\Workspace\Local-CI-CD-System\scripts\Invoke-CIJob.ps1' `
-JobId '${{ github.run_id }}' `
-RepoUrl 'ssh://gitea-ci/Simone/<repo>.git' `
-Branch '${{ github.ref_name }}' `
-Commit '${{ github.sha }}' `
-TemplatePath $env:GITEA_CI_TEMPLATE_PATH `
-Submodules `
-BuildCommand 'python build_plugin.py --final --dist-dir dist' `
-GuestArtifactSource 'dist'
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
```
> Il parametro `-VMIPAddress` **non è più necessario** — l'IP viene rilevato automaticamente
> tramite `vmrun getGuestIPAddress` dopo l'avvio della VM.
---
### Step 4 — Invoke-CIJob.ps1: Clone VM
+14 -14
View File
@@ -35,16 +35,16 @@ Tier 0: Base OS Install (Windows only, no tools)
Tier 1: Build Toolchain
└── Snapshot: "BaseClean" ← CLONE SOURCE (weekly refresh)
Includes: VS Build Tools 2022, .NET SDK, Git, WinRM config
Includes: VS Build Tools 2026, .NET SDK 10.0.203, Python 3.13.3, Git, WinRM config
Requirement: ALL linked clones must reference this exact snapshot
```
### Refresh Schedule
| Snapshot | Refresh Frequency | Trigger |
|----------|------------------|-------|
| `OSBase` | Quarterly | Windows cumulative update |
| `BaseClean` | Weekly/Monthly | .NET SDK patch, security update, VS update |
| Snapshot | Refresh Frequency | Trigger |
| ----------- | ----------------- | ------------------------------------------ |
| `OSBase` | Quarterly | Windows cumulative update |
| `BaseClean` | Weekly/Monthly | .NET SDK patch, security update, VS update |
> **Note:** Windows Server 2025 KMS lease = 180 giorni. Prima della scadenza:
> boot template su VMnet8 (NAT) → `slmgr /ato` → spegni → nuovo snapshot `BaseClean`.
@@ -55,15 +55,15 @@ Tier 1: Build Toolchain
### RAM Budget (i9-10900X · 64 GB)
| Component | RAM Usage |
|-----------|----------|
| Windows host OS | ~4 GB |
| VMware Workstation | ~0.5 GB |
| Gitea server | ~0.51 GB |
| act_runner service | ~100 MB |
| Each build VM (idle) | ~23 GB |
| Each build VM (active MSBuild/Python) | ~68 GB |
| **Headroom target (20%)** | ~13 GB |
| Component | RAM Usage |
| ------------------------------------- | --------- |
| Windows host OS | ~4 GB |
| VMware Workstation | ~0.5 GB |
| Gitea server | ~0.51 GB |
| act_runner service | ~100 MB |
| Each build VM (idle) | ~23 GB |
| Each build VM (active MSBuild/Python) | ~68 GB |
| **Headroom target (20%)** | ~13 GB |
```
Available for VMs: 64 - 4 - 0.5 - 1 - 0.1 - 13 = ~45 GB
+4 -9
View File
@@ -31,14 +31,8 @@ jobs:
# GITEA_CI_TEMPLATE_PATH is injected by runner/config.yaml global envs
# GITEA_CI_CLONE_BASE_DIR is injected by runner/config.yaml global envs
# IP address for this build VM.
# For parallel builds, each concurrent job needs a unique IP.
# Assign via Gitea matrix or a simple offset scheme.
# Example: use a fixed IP per runner slot, mapped by capacity index.
# For single concurrent builds: use one fixed IP.
BUILD_VM_IP: "192.168.11.101"
# Gitea Credential Manager target (set in runner/config.yaml)
# The VM IP is auto-detected via vmrun getGuestIPAddress — no BUILD_VM_IP needed.
GUEST_CRED_TARGET: "BuildVMGuest"
steps:
@@ -66,8 +60,9 @@ jobs:
-RepoUrl "${{ github.server_url }}/${{ github.repository }}.git" `
-Branch "${{ github.ref_name }}" `
-Commit "${{ github.sha }}" `
-Configuration "Release" `
-VMIPAddress "$env:BUILD_VM_IP" `
-Submodules `
-BuildCommand 'python build_plugin.py --final --dist-dir dist' `
-GuestArtifactSource 'dist' `
-GuestCredentialTarget "$env:GUEST_CRED_TARGET"
if ($LASTEXITCODE -ne 0) {