Skip to content

Adds a pipeline for sandboxing containers#1260

Open
wonderyl wants to merge 8 commits into
v2from
yaolei/kata
Open

Adds a pipeline for sandboxing containers#1260
wonderyl wants to merge 8 commits into
v2from
yaolei/kata

Conversation

@wonderyl

@wonderyl wonderyl commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

wonderyl and others added 6 commits July 16, 2026 00:01
New pipeline creates an AKS cluster with a Kata VM-isolation
(KataMshvVmIsolation) node pool, schedules a pause pod using the
kata-mshv-vm-isolation runtime class, measures pod startup latency
from pod events, and uploads the JSON result to the telescopev2
storage account for Kusto ingestion.

Co-authored-by: Lei Yao <yaolei@microsoft.com>
Co-Authored-By: Claude <noreply@anthropic.com>
…n cluster

Per MS Learn doc, the runtime class exposed by KataVmIsolation is
kata-vm-isolation, and 'az aks update' must be run after adding the
Kata node pool for pod sandboxing to be enabled cluster-wide.

Co-authored-by: Lei Yao <yaolei@microsoft.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Kubernetes lastTransitionTime can carry sub-second precision (e.g.
2026-07-16T04:49:58.998786Z), which strptime %S rejects. Use
datetime.fromisoformat after normalizing the trailing Z.
Split the inline pod YAML into pod.yaml and the inline Python into
measure.py; pipeline.k now applies the manifest and invokes the script
via $(Build.SourcesDirectory).
Comment thread kcl/aks_pod_sandboxing/pipeline.k Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new AKS “pod sandboxing” measurement pipeline that provisions a Kata-enabled AKS cluster, schedules a minimal pause pod using a Kata runtime class, computes startup latency from Kubernetes events, and uploads the result JSON to the Telescope storage account.

Changes:

  • Adds a Pod manifest (pod.yaml) for a Kata-isolated pause pod.
  • Adds a new Azure Pipelines definition (pipeline.k + generated pipeline.yaml) to create the cluster, run the measurement, upload results, and delete the resource group.
  • Adds a Python measurement script (measure.py) that extracts timestamps from pod/events and writes /tmp/run-result.json.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.

File Description
kcl/aks_pod_sandboxing/pod.yaml Defines the pause pod using runtimeClassName: kata-vm-isolation.
kcl/aks_pod_sandboxing/pipeline.yaml Azure Pipelines YAML to provision AKS, run the pod, measure, upload, and clean up.
kcl/aks_pod_sandboxing/pipeline.k KCL source for generating the pipeline and composing shared steps.
kcl/aks_pod_sandboxing/measure.py Measurement script computing startup latency and emitting /tmp/run-result.json.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread kcl/aks_pod_sandboxing/measure.py
Comment thread kcl/aks_pod_sandboxing/measure.py
Comment thread kcl/aks_pod_sandboxing/pipeline.k Outdated
Comment thread kcl/aks_pod_sandboxing/pipeline.k
Comment thread kcl/aks_pod_sandboxing/pipeline.k Outdated
Comment thread kcl/aks_pod_sandboxing/measure.py Outdated
Comment thread kcl/aks_pod_sandboxing/measure.py
wonderyl added 2 commits July 19, 2026 21:58
Replace static pod.yaml with pod.k that takes podName, runtimeClass,
image as individual options. Pipeline installs KCL at runtime, renders
the manifest into $(Pipeline.Workspace)/pod.yaml, then applies it.
measure.py reads pod/cluster metadata from environment variables.
Pod manifest now defined directly with core_v1.Pod (with option()
parameters for podName/runtimeClass/image). UploadResult now uses
DEFAULT_STORAGE_* constants instead of hard-coded literals.
@@ -0,0 +1,19 @@
import k8s.api.core.v1 as core_v1

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we move this into a shared library so other pipelines can reuse it? We could introduce a helper like apply_dummy_pod.k to apply a dummy pod for testing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants