Skip to content

feat: enable artifact streaming on ACL - #9613

Open
rguptar wants to merge 15 commits into
mainfrom
guptar/acl/artifactstreaming
Open

rguptar wants to merge 15 commits into
mainfrom
guptar/acl/artifactstreaming

Conversation

@rguptar

@rguptar rguptar commented Sep 22, 2026 •

Copy link
Copy Markdown

What this PR does / why we need it:

Enables Artifact Streaming on ACL using the combined ACR mirror, OverlayBD, and overlaybd-snapshotter system extension from mcr.microsoft.com/azurecontainerregistry/v2/artifact-streaming-sysext.

  • Cache the architecture-specific sysext in the VHD instead of installing the ACR RPM or enabling ACL's separate OverlayBD extension.
  • Keep streaming units masked until the feature-enabled node reaches nodePrep, including on PIS-cached VHDs. Use the same provisioning path for CSE and node-controller rather than an early Ignition setup service.
  • Initialize the sysext's writable paths, preserve/materialize containerd configuration, and configure ACR before starting consumers. Propagate setup failures before kubelet starts.
  • Resolve the exact pinned DALEC revision for both architectures, including network-isolated registries without tag-listing support.
  • Preserve the existing Ubuntu and regular Azure Linux package paths, and extend ACL scenarios to cover enabled and disabled behavior.

The initial pin is v1.0.0-1-azlinux3, with -x86-64 and -arm64 architecture suffixes. VHD builds depend on those artifacts being published to the repository above.

Copilot AI balanced review requested due to automatic review settings September 22, 2026 17:02
@rguptar
rguptar requested review from a team as code owners September 22, 2026 17:02
@github-actions github-actions Bot added the components This pull request updates cached components on Linux or Windows VHDs label Sep 22, 2026
@github-actions

github-actions Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Windows Unit Test Results

  3 files   18 suites   55s ⏱️
662 tests 662 ✅ 0 💤 0 ❌
685 runs  685 ✅ 0 💤 0 ❌

Results for commit 93408b9.

♻️ This comment has been updated with latest results.

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.

Copilot review overview

🟡 Changes recommended

The ACL installer and end-to-end artifact-streaming path lack coverage for package extraction, sysext activation, and real service startup.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 Low severity

Open (1)
What changed in this PR

Enables artifact streaming on Azure Container Linux using the OverlayBD system extension and ACL-specific acr-mirror installation.

Changes:

  • Adds ACL package selection and RPM extraction.
  • Configures OverlayBD sysext and service lifecycle.
  • Extends schemas, documentation, and unit fixtures.
File Description
vhdbuilder/​packer/​install-dependencies.sh Installs and initializes acr-mirror on ACL.
vhdbuilder/​packer/​acl-customdata.yaml Enables OverlayBD sysext and masks services initially.
vhdbuilder/​packer/​acl-customdata.json Regenerates ACL Ignition configuration.
spec/​parts/​linux/​cloud-init/​artifacts/​test_components.json Adds ACL and Flatcar test metadata.
spec/​parts/​linux/​cloud-init/​artifacts/​cse_helpers_spec.sh Tests ACL metadata selection and fallback.
spec/​parts/​linux/​cloud-init/​artifacts/​cse_config_gpu_spec.sh Tests ACL service unmasking.
schemas/​components.cue Adds ACL component metadata schema.
parts/​linux/​cloud-init/​artifacts/​README-COMPONENTS.md Documents ACL metadata behavior.
parts/​linux/​cloud-init/​artifacts/​cse_helpers.sh Selects ACL-specific package entries.
parts/​linux/​cloud-init/​artifacts/​cse_config.sh Unmasks OverlayBD services during provisioning.
parts/​common/​components.json Adds the ACL acr-mirror package entry.

💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +214 to +219
if isACL "$OS" "$OS_VARIANT"; then
bsdtar -C / -xf "$MIRROR_DOWNLOAD_PATH" opt/ || exit "$ERR_ARTIFACT_STREAMING_DOWNLOAD"
bsdtar -Oxf "$MIRROR_DOWNLOAD_PATH" usr/lib/systemd/system/acr-mirror.service |
install -m 0644 /dev/stdin /etc/systemd/system/acr-mirror.service ||
exit "$ERR_ARTIFACT_STREAMING_DOWNLOAD"
env -C /opt/acr/bin ./acr init --min-init || exit "$ERR_ARTIFACT_STREAMING_DOWNLOAD"
@aks-node-assistant

Copy link
Copy Markdown
Contributor

AgentBaker Linux gate detective

Run: https://msazure.visualstudio.com/CloudNativeCompute/_build/results?buildId=182278061
Failed job/stage/task: build / buildaclarm64fipstlgen2 / Build VHD (same signature appears across ACL artifact-streaming build lanes).

Detective summary: Packer entered install-dependencies.sh for the ACL artifact-streaming image and failed while handling the ACR mirror package because bsdtar was not installed: /home/packer/install-dependencies.sh: line 215: bsdtar: command not found. Packer then exited non-zero (Script exited with non-zero exit status: 152).

Likely cause / signature: $sigBsdtar.

Confidence: High for PR-change-caused dependency/setup regression.

Recommended owner/action: PR #9613 should install or otherwise guarantee �sdtar before artifact-streaming extraction, or avoid the �sdtar dependency in install-dependencies.sh for ACL images.

Strongest alternative: transient package/feed outage; less likely because downloads immediately before the failure succeeded and the primary error is the local command missing, not an HTTP/package fetch failure.

Evidence: Timeline marks ACL Build VHD tasks failed; Build VHD log reaches artifact-streaming downloads then fails with bsdtar: command not found; PR metadata shows changes to install-dependencies.sh, cse_helpers.sh, and ACL customdata/component files.

Wiki signature: $sigBsdtar

Copilot AI review requested due to automatic review settings September 22, 2026 21:54

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.

Copilot review overview

🟡 Changes recommended

Critical ACL build-tool and backward-compatibility failures, plus incorrect package setup logic, must be resolved.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 2 High severity · 1 Medium severity · 1 Low severity

Open (4)

Comment thread parts/linux/cloud-init/artifacts/cse_config.sh Outdated
Comment thread vhdbuilder/packer/install-dependencies.sh Outdated
Comment thread aks-node-controller/pkg/nodeconfigutils/utils.go Outdated
@aks-node-assistant

Copy link
Copy Markdown
Contributor

AgentBaker Linux gate detective

Run: https://msazure.visualstudio.com/CloudNativeCompute/_build/results?buildId=182333136
Failed job/stage/task: build / ACL artifact-streaming Build VHD lanes (buildacltlgen2, buildaclfipstlgen2, buildaclarm64*) plus Test/Scan lanes.

Detective summary: ACL artifact-streaming Build VHD failed again when install-dependencies.sh attempted to extract ACR mirror content using bsdtar and hit bsdtar: command not found; Packer exited 152. The same build also repeated the repair-linked FIPS CIS 5.1.18/5.1.6 drift and the noisy 6.1.3.1 CIS drift in ARM64 22.04 Test/Scan.

Likely cause / signature: vhd-acl-artifact-streaming-bsdtar-command-not-found; secondary signatures vhd-ubuntu2204fips-cis-cron-rules-regression and vhd-ubuntu2204fips-cis-rule-6-1-3-1-regression.

Confidence: High for PR-change-caused ACL artifact-streaming dependency/setup regression; high for recurring CIS baseline drift.

Recommended owner/action: PR #9613 should install or guarantee �sdtar before artifact-streaming extraction, or remove the �sdtar dependency; VHD validation owners should continue repair #39802117 for the separate CIS drift.

Strongest alternative: transient package/feed outage; less likely because the primary Build VHD error is the local command missing after downloads succeeded, and the same signature was previously observed on this PR.

Evidence: Timeline marks ACL Build VHD tasks failed; Build VHD logs show bsdtar: command not found followed by Packer exit 152; Test/Scan logs show 5.1.18|pass->fail, 5.1.6|pass->fail, and 6.1.3.1|pass->fail; PR metadata changes artifact-streaming/customdata/install-dependencies paths.

Wiki signatures: $sigBsdtar, $sigCis, $sigRule

Copilot AI review requested due to automatic review settings September 22, 2026 23:04

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.

Copilot review overview

🔵 Needs a closer look

Three moderate provisioning and cross-platform compatibility issues remain unresolved.

Review effort: Balanced
Findings: 2 High severity · 1 Medium severity · 1 Low severity

Open (4)

Copilot AI review requested due to automatic review settings September 22, 2026 23:24

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.

Copilot review overview

🟡 Changes recommended

Critical ACL build and provisioning-path issues prevent artifact streaming from being configured reliably.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 4 High severity · 1 Medium severity · 1 Low severity

Open (6)
Resolved since last review (1)

Comment thread aks-node-controller/pkg/nodeconfigutils/utils.go Outdated
Comment on lines +638 to +641
if isACL "$OS" "$OS_VARIANT"; then
systemctl unmask overlaybd-tcmu.service overlaybd-snapshotter.service || exit "$ERR_ARTIFACT_STREAMING_INSTALL"
fi
retrycmd_if_failure 120 5 25 systemctl --quiet enable --now acr-mirror overlaybd-tcmu overlaybd-snapshotter || exit "$ERR_ARTIFACT_STREAMING_INSTALL"
Comment thread vhdbuilder/packer/install-dependencies.sh Outdated
Copilot AI review requested due to automatic review settings September 22, 2026 23:36

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.

Comment thread aks-node-controller/pkg/nodeconfigutils/utils.go Outdated
Comment thread vhdbuilder/packer/install-dependencies.sh Outdated
Copilot AI review requested due to automatic review settings September 23, 2026 00:02

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.

@aks-node-assistant

Copy link
Copy Markdown
Contributor

AgentBaker Linux gate detective

Run: https://msazure.visualstudio.com/CloudNativeCompute/_build/results?buildId=182357334
Failed job/stage/task: e2e / Run AgentBaker E2E / LocalDNSHostsPlugin AzureLinuxV3, Ubuntu2204, and Ubuntu2404; build build2204fipsgen2containerd Test/Scan also repeated the repair-linked CIS baseline drift.

Detective summary: E2E reported 184 scenarios with 4 failed and 0 flaky. LocalDNS restart-budget validation injected a failing ExecStart=/bin/false, but localdns stayed active after 120s instead of reaching terminal failed/start-limit-hit, so unrecoverable faults would not be bounded. The same run also repeated CIS 5.1.18/5.1.6 scan drift under repair #39802117.

Likely cause / signature: e2e-localdns-restart-budget-hungstart-not-bounded; secondary recurring signature vhd-ubuntu2204fips-cis-cron-rules-regression.

Confidence: High for deterministic LocalDNS restart-budget validation regression; high for recurring CIS drift.

Recommended owner/action: PR #9613 owner should inspect LocalDNS restart-budget behavior now that artifact streaming changes touch scenario selection/config; VHD validation owners should continue repair #39802117 for the separate CIS drift.

Strongest alternative: shared systemd timing flake; less likely because three LocalDNSHostsPlugin variants fail the same injected-fault assertion and the suite reported zero flaky tests.

Evidence: E2E log reports localdns is active after 120s ... expected failed and LocalDNS did not reach terminal failed after exhausting its restart budget; final summary shows 0 flaky tests; timeline marks Run AgentBaker E2E failed; Test/Scan log separately reports 5.1.18|pass->fail and 5.1.6|pass->fail.

Wiki signatures: $sigLocal, $sigCis

Copilot AI review requested due to automatic review settings September 23, 2026 02:27

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.

Copilot review overview

🟡 Changes recommended

Critical and moderate issues remain in package integrity/tooling and systemd provisioning order and dependencies.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 7 High severity · 1 Low severity

Open (8)
Resolved since last review (1)

Comment thread aks-node-controller/pkg/nodeconfigutils/utils.go Outdated
Comment thread vhdbuilder/packer/install-dependencies.sh Outdated
Copilot AI review requested due to automatic review settings September 23, 2026 23:32
rguptar and others added 3 commits October 28, 2026 11:29
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Cache mcr.microsoft.com/acr/v2/artifact-streaming-sysext instead of installing
the ACR RPM or enabling a separate OverlayBD extension. Keep exact DALEC
revision and architecture pins for local and network-isolated delivery.

Defer activation to nodePrep for both CSE and node-controller. Initialize
writable paths and ACR configuration before unmasking consumers, preserve
GPU containerd settings when materializing its symlink, and fail provisioning
before kubelet starts if setup fails. Keep other OS package paths unchanged.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0d5fc628-3611-41e9-b6d6-55b92081296b
@rguptar
rguptar force-pushed the guptar/acl/artifactstreaming branch from fb68abe to ce65176 Compare October 28, 2026 18:31

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.

Comment on lines +632 to +633
if [ "${ARTIFACT_STREAMING_ENABLED}" = "true" ] && isACL "$OS" "$OS_VARIANT"; then
logs_to_events "AKS.CSE.ensureContainerd.ensureArtifactStreaming" ensureArtifactStreaming || exit $ERR_ARTIFACT_STREAMING_INSTALL
Copilot AI balanced review requested due to automatic review settings October 28, 2026 18:32

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.

🟡 Changes recommended

The streaming scenario enables Secure Boot unconditionally, preventing unsigned ACL images from booting, while tests leave provisioning-phase gating, cached-node activation, and setup-failure propagation unverified.

4 open issues

Review effort: Balanced

Comment thread e2e/scenario/scenario.go
config.EnableArtifactStreaming = true
},
VMConfigMutator: func(vmss *armcompute.VirtualMachineScaleSet) {
vmss.Properties = addTrustedLaunchToVMSS(vmss.Properties)
Comment thread parts/linux/cloud-init/artifacts/cse_main.sh
Check each decoded JSON type assertion and guard the file list before
indexing it, satisfying errcheck without suppressing lint findings.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0d5fc628-3611-41e9-b6d6-55b92081296b
Copilot AI balanced review requested due to automatic review settings October 28, 2026 20:17
Use azurecontainerregistry/v2/artifact-streaming-sysext for VHD caching,
Renovate metadata, and node provisioning, retaining the pinned version
and registry overrides. Update the matching ShellSpec expectations.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0d5fc628-3611-41e9-b6d6-55b92081296b

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.

🔵 Needs a closer look

The scenario unconditionally enables Secure Boot, ignoring the unsigned ACL image setting and preventing those images from booting or reaching streaming validation.

4 open issues

Review effort: Balanced

Copilot AI balanced review requested due to automatic review settings October 28, 2026 20:26
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0d5fc628-3611-41e9-b6d6-55b92081296b

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.

🟡 Changes recommended

The scenario forces Secure Boot and prevents unsigned ACL images from booting, while the new sysext repository lacks the Renovate rule needed to match published version tags.

5 open issues

Review effort: Balanced

Comment thread parts/common/components.json Outdated
Comment on lines +2534 to +2535
"renovateTag": "OCI_registry=https://mcr.microsoft.com, name=azurecontainerregistry/v2/artifact-streaming-sysext",
"latestVersion": "v1.0.0-2-azlinux3"
Use v1.0.0-1-azlinux3 and update the exact-revision resolution and VHD caching tests to match the initial component publication.

Validated: 25 focused ShellSpec examples, 0 failures; JSON pin, shell syntax, and whitespace checks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: da9d0569-0965-44eb-9e2b-1d2ac995e638
Copilot AI balanced review requested due to automatic review settings October 28, 2026 21:18

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.

🔵 Needs a closer look

Unconditional Secure Boot prevents unsigned ACL images from booting, and the missing DALEC Renovate rule prevents automatic updates to the new sysext pin.

5 open issues

Review effort: Balanced


if [ "${ARTIFACT_STREAMING_ENABLED}" = "true" ]; then
# Defer ACL artifact streaming to nodePrep: keep sysext services masked
# during PIS image preparation and activate them on the real node.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Can you explain why we need to defer?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

"PIS images already contain base_prep.complete, so real nodes skip basePrep. nodePrep runs on real provisioning but not pre-provision-only image preparation."

@@ -635,9 +635,29 @@ EOF
}

ensureArtifactStreaming() {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is this and IPE mutually exclusive?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I don't know the answer to this.

Comment thread vhdbuilder/packer/acl-customdata.yaml Outdated
@@ -392,29 +392,37 @@ downloadAndInstallCriTools() {
installAndConfigureArtifactStreaming() {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is the caller conditioned on artifact streaming enabled and IPE disabled?

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.

no, this will be called for all VHD flavors that have a corresponding acr-mirror entry in components.json at build time - as the comment says this is a caching operation only, usage of acr-mirror is gated at node provisioning time

fi

# Keep ACL sysexts masked during PIS image preparation; configure them on the real node.
if [ "${ARTIFACT_STREAMING_ENABLED}" = "true" ] && isACL "$OS" "$OS_VARIANT"; then

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Just to confirm, is ARTIFACT_STREAMING_ENABLED set to false by default?

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.

it's set and passed down by AKS RP - it will default to false

Remove the unverified enabled-sysext.conf entry from ACL custom data and regenerate Ignition JSON using strict Butane validation. Preserve all remaining configuration and streaming service masks.

Validated: strict Butane regeneration, Ignition configuration equivalence apart from the removed entry, 28 focused ShellSpec examples, and whitespace checks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: da9d0569-0965-44eb-9e2b-1d2ac995e638
Copilot AI balanced review requested due to automatic review settings October 28, 2026 22:35
@github-actions

Copy link
Copy Markdown
Contributor

Code Coverage

Package Line Rate Health
test 0% ❌
windows 27% ❌
staging_cse_windows Package 1 68% ➖
debug 0% ❌
provisioningscripts 2% ❌
parts_windows Package 1 73% ➖
Summary 39% (1819 / 7001) ❌

@github-actions

Copy link
Copy Markdown
Contributor

Code Coverage

Package Line Rate Health
github.com/Azure/agentbaker/aks-node-controller 73% ➖
github.com/Azure/agentbaker/aks-node-controller/common 100% ✔
github.com/Azure/agentbaker/aks-node-controller/helpers 68% ➖
github.com/Azure/agentbaker/aks-node-controller/parser 88% ✔
github.com/Azure/agentbaker/aks-node-controller/pkg/gpu 100% ✔
github.com/Azure/agentbaker/aks-node-controller/pkg/nodeconfigutils 91% ✔
github.com/Azure/agentbaker/aks-node-controller/utils 0% ❌
github.com/Azure/agentbaker/apiserver 24% ❌
github.com/Azure/agentbaker/cmd 0% ❌
github.com/Azure/agentbaker/cmd/starter 0% ❌
github.com/Azure/agentbaker/fuzz/api 0% ❌
github.com/Azure/agentbaker/hotfix/render-nodecustomdata 35% ❌
github.com/Azure/agentbaker/pkg/agent 78% ➖
github.com/Azure/agentbaker/pkg/agent/datamodel 77% ➖
github.com/Azure/agentbaker/pkg/agent/toggles 0% ❌
github.com/Azure/agentbaker/pkg/vhdbuilder/datamodel 87% ✔
Summary 75% (6037 / 8001) ➖

@github-actions

Copy link
Copy Markdown
Contributor

Code Coverage

Package Line Rate Health
shellspec spec 29% ❌
Summary 29% (4731 / 16403) ❌

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.

🔵 Needs a closer look

The scenario unconditionally enables Secure Boot instead of respecting ACLBaseImageSigned, causing unsigned development images to fail to boot before artifact-streaming checks can run.

5 open issues

Review effort: Balanced

This branch has not been deployed

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

Labels

components This pull request updates cached components on Linux or Windows VHDs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants