Cloud Servers

AWS Lambda Customer-Managed Runtimes: Patch Once, Every Function Updates — Who Should Switch?

13 min read

AWS Lambda Customer-Managed Runtimes: Patch Once, Every Function Updates — Who Should Switch?

The Short Answer

AWS Lambda now lets you own the runtime itself. Customer-managed runtimes, generally available since November 18, 2026 in all commercial AWS Regions at no additional charge, turn the Lambda runtime into a standalone resource that a platform team publishes once — as a container image in Amazon ECR — and every function that references it picks up updates automatically at its next cold start. No more redeploying hundreds of functions to ship one security patch. If you run a handful of functions on Python or Node.js and are happy letting AWS patch the runtime, nothing changes for you and nothing needs to. If you run PHP on Lambda, standardize security or monitoring agents across an organization, or have ever spent a day redeploying functions because a shared layer changed, this is the most useful Lambda launch of the month — and it arrives in the same busy week as the 30-minute Lambda timeout and GPU support on Lambda Managed Instances.

The catch is in the name: customer-managed means you manage it. AWS no longer patches your runtime, you own backward compatibility, and whoever publishes the runtime can push code into every execution environment that consumes it. This article explains how the model works, what it replaces, and where the line sits between “obvious upgrade” and “new way to break everything at once.”

What AWS Launched

Until this month, Lambda Event Functions (the renamed standard Lambda functions) ran only on runtimes AWS manages. You picked a language — Python, Node.js, Java, and so on — deployed your code as a .zip file, and AWS owned patching and lifecycle. Anything extra your organization required in every function, such as an approved SDK version, enterprise certificates, a security agent, or an entire unsupported language like PHP, had to be bolted on per function.

Customer-managed runtimes add a third model. A runtime is now its own Lambda resource, built from an OCI container image stored in Amazon ECR, using the same Docker and CI/CD tooling teams already have. The runtime has immutable versions (each backed by one ECR image) and named aliases that point to a version. A function references a runtime alias — for example production — in its configuration and keeps deploying ordinary .zip files with the same CLI and tools as before. When the publisher moves the alias to a new version, functions pick it up as Lambda recycles execution environments, with no redeployment and no rollout coordination across teams.

Three launch facts matter for budgeting and planning. First, there is no additional charge: functions on a customer-managed runtime cost the same as functions on a Lambda-managed runtime, and creating versions and aliases is free. The only new line item is standard Amazon ECR storage for the runtime images, which the publisher must keep for as long as each version exists. Second, the feature is generally available in all commercial AWS Regions, manageable through the console, CLI, SDKs, CloudFormation, CDK, and SAM. Third, it applies to Lambda Event Functions only — Lambda Web Functions are not covered at launch. AWS also renamed the old custom-runtimes feature to “bring your own language” to clear up the naming.

The Problem It Solves: The Redeploy Tax

The old ways to share components across functions both taxed every team. Lambda Layers distribute shared libraries as versioned .zip files, but they follow a pull model: when a layer is updated, every function that uses it must be redeployed to pick up the change. Container image packaging gives full control over the runtime contents, but it pushes Dockerfiles, registries, and image builds onto every developer on every team, and every shared-component update means rebuilding and redeploying every function image. You also lose .zip deployment simplicity and automatic runtime updates.

For an organization with thousands of functions, that tax is paid on every patch. A critical fix in a monitoring agent or a language runtime becomes a fleet-wide redeploy campaign, and the functions that miss the campaign keep running the vulnerable version. Customer-managed runtimes remove the campaign: update the runtime once, move the alias, and the fleet converges on the new version as environments recycle. AWS explicitly positions this for standardizing shared components at scale, running languages Lambda does not support (PHP, Bun, and R are the named examples), controlling your own patching cadence, and extending the life of a runtime AWS has deprecated by forking it and patching it yourself.

Model Who patches the runtime How an update reaches functions Developer experience Best for
Lambda-managed runtime AWS Automatically, on AWS’s schedule Pick a language, deploy .zip Most teams; anyone new to serverless
Lambda Layers You (per layer version) Redeploy every function using the layer .zip + layer ARNs to manage Sharing libraries across a few functions
Container image functions You (per function image) Rebuild + redeploy every function image Dockerfiles, registries, image builds for every dev Full control of one function’s environment
Customer-managed runtime You (centrally, once) Move the alias; functions update at next cold start .zip, same CLI; runtime referenced by alias ARN Platform teams, PHP/Bun/R, org-wide agents and certs

How It Works: Publishers, Consumers, and Aliases

The model splits responsibility into two roles. The runtime publisher — typically a central cloud platform team — owns the runtime contents, updates, access control, and lifecycle: building the image (from a Lambda base image, which AWS keeps patched, or from scratch), publishing versions, and deciding who may use the runtime. The runtime consumer is the function developer, who references the runtime alias, writes handler code, deploys .zip files, and never touches the underlying image.

Rollouts are designed to be staged rather than big-bang. Aliases can be split by environment (dev, test, prod), by release track (latest, stable), or by semantic version (php8.3, php8.4). Runtimes are Regional resources, so a publisher creates them per Region — ideally with consistent names and ECR cross-Region replication — and can roll alias updates Region by Region. Two CloudWatch metrics in the publisher’s account, RuntimeInvocations and RuntimeInvocationErrors, can be viewed by runtime, version, or alias, so a bad version shows up as a rising error rate before the rollout proceeds. Rollback is re-pointing the alias to the previous version. AWS recommends alarming on each alias’s error rate and halting the pipeline automatically when an alarm fires — sound advice, because the same mechanism that makes patching instant also makes breaking changes instant.

Sharing works across accounts and organizations: a resource-based policy on the runtime grants access to specific accounts, an AWS Organization or organizational unit, or the public, and consumers additionally need the lambda:AssociateRuntimeAlias permission. Organization administrators can use service control policies to allow only runtimes from trusted accounts or block external runtimes entirely. Deletion has guardrails, because deleting a runtime can break functions in other accounts: deletion is scheduled with a 7-to-30-day waiting period (30 by default) during which the resource can be restored, a version cannot be deleted while an alias points to it, and functions on a deleted alias enter the Inactive state and fail on cold start until it is restored. Publishers can also set a lifecycle stage (Preview, GenerallyAvailable, Deprecated) and block new function creation after a date, giving deprecated runtimes a managed exit instead of a cliff.

The PHP Proof: Bref v4

The clearest early adopter is Bref, the open-source project that runs PHP applications (Laravel, Symfony, and plain PHP) on Lambda. Bref v3 delivers PHP through Layers, so every PHP security release requires every application to update and redeploy. That cost became concrete twice this autumn: when PHP shipped critical PHP-FPM remote-code-execution fixes in October, Bref published patched layers 31 minutes after the PHP release — but each application still had to redeploy on its own schedule, and some were likely still vulnerable days later. The same cycle repeated with another critical PHP update on November 19.

Bref v4, planned for the end of 2026, will switch entirely to customer-managed runtimes — one runtime per PHP version in every Region Bref supports, built on Ubuntu 26.04 LTS instead of Amazon Linux, with PHP 8.6 support (released November 19). A PHP security fix then becomes a new runtime version rolling out at each function’s next cold start, with no application redeploy. Bref’s creator, who tested the feature privately with the Lambda team, also measured a side benefit: shipping the exact same PHP binaries as a customer-managed runtime instead of a Layer cut PHP-FPM cold starts by 29% (279 ms to 197 ms in his test), because Lambda caches and lazily loads the image instead of downloading and extracting a layer .zip in every new environment. His v4 prototype started roughly 100 ms faster than v3 on a Laravel application and used less memory (59 MB versus 72 MB for PHP-FPM). Those are one project’s measurements on ARM64 with 1,024 MB functions, not AWS guarantees — but they show the delivery mechanism itself is not a tax. Even if you never run PHP on Lambda, Bref is the first public proof that a third-party runtime can be maintained with the same patch velocity as an official one — previously something only AWS could do.

What It Means If You Run Servers

If you manage VPS or dedicated servers, this launch will feel familiar: it is the golden image pattern, applied to serverless. On a VPS fleet, you build one hardened image with your approved agents and certificates, roll it out host by host, and watch error rates before proceeding. Customer-managed runtimes are the same idea with aliases instead of image IDs and cold starts instead of reboots — version everything, stage rollouts, alarm on error rates, keep rollback one step away. Teams that already run Docker on a VPS will find the ECR image workflow unremarkable, which is precisely the point.

The trust model deserves the same scrutiny you would give any golden image. A runtime publisher can push code into the execution environments of every function that consumes the runtime — by design, since that is how updates work — and can also ship a breaking update or delete the runtime. Consuming a third-party runtime therefore means trusting that publisher the way you would trust anyone who can run code with your permissions. The mitigations are the usual ones: consume only from accounts you trust, govern allowed runtimes with service control policies, scan runtime images with your existing container tooling, and consider building your own runtime from a third party’s images if you want their contents under your control.

Who should switch, concretely: platform teams standardizing agents, certificates, or SDK versions across many accounts and functions (the headline use case, with immediate savings); PHP, Bun, R, or other unsupported-language workloads on Lambda, especially via Bref once v4 ships; and anyone pinned to a deprecated managed runtime who needs more migration time — fork it, patch it yourself, deprecate on your own schedule. If you run a few functions on a managed runtime and AWS’s patching already suits you, stay put: it costs nothing and keeps the smallest operational surface.

Limits and Fine Print

Four limits should be in the decision. First, you own patching now: Lambda does not patch customer-managed runtimes, and while starting from a Lambda base image helps (AWS updates those with security patches), rebuilding, publishing, testing, and rolling out each version is your pipeline’s job. Second, updates must be backward-compatible with every consuming function, because consumers do not choose when the alias moves unless they pin to a version — a change that suits one team can break another’s, and the blast radius is the whole fleet, so staged aliases and error-rate alarms are not optional garnish. Third, runtimes are Regional: multi-Region estates need the runtime, versions, and aliases recreated per Region, with ECR replication to distribute images. Fourth, Event Functions only at launch — Lambda Web Functions stay on the old models for now. Add the ECR storage cost for retained versions (small, but it grows if you keep every version forever), and the honest summary is: the feature is free, the discipline is not.

FAQ

What is a customer-managed runtime in AWS Lambda?
A standalone Lambda resource, built from an OCI container image in Amazon ECR, that functions reference through an alias instead of a Lambda-managed language runtime. The publisher owns its contents and updates; functions keep deploying .zip files and receive runtime updates automatically at cold start.

When did it launch, and where?
Generally available since November 18, 2026, in all commercial AWS Regions, for Lambda Event Functions — manageable via the console, CLI, SDKs, CloudFormation, CDK, and SAM.

How much does it cost?
No additional charge: functions cost the same as on a Lambda-managed runtime, and creating versions and aliases is free. Publishers pay standard ECR storage for the runtime images while each version exists.

How is this different from Layers or container image functions?
Layers require redeploying every function to pick up an update; container image functions require every developer to rebuild and redeploy images for shared changes. A customer-managed runtime is updated once centrally — moving its alias rolls the change to all consuming functions at their next cold start, while developers keep the .zip workflow.

Can I run PHP on Lambda with this?
Yes — PHP is one of AWS’s named examples. Bref will publish PHP runtimes as customer-managed runtimes in Bref v4 (planned for the end of 2026), including PHP 8.6, so PHP security patches will reach applications without a redeploy. Until v4 ships, Bref v3 on Layers keeps working unchanged.

What happens if a runtime update breaks my functions?
Roll back by re-pointing the alias to the previous version; functions recover as environments recycle. Watch RuntimeInvocationErrors by version and alias during rollout. Consumers with the right permissions can also pin to a specific runtime version.

Is it safe to use a runtime published by someone else?
Only with the same trust you would give anyone who can run code with your permissions — a publisher can push updates into your functions’ execution environments or delete the runtime. Restrict allowed publishers with service control policies, scan images with your container tooling, or rebuild the runtime under your own account from the publisher’s images.

The Bottom Line

Customer-managed runtimes close the last big operational gap between Lambda-managed runtimes and self-managed infrastructure: central control without per-function redeploys. For platform teams and PHP-on-Lambda shops, adopting them is close to a no-brainer — the Bref v4 plan shows why, with security patches rolling out at cold start and measurably faster starts as a bonus. For everyone else, the feature is safely ignorable until the day a shared layer or a deprecated runtime makes the redeploy tax personal. Either way, treat a runtime alias like a production image tag: stage it, alarm on it, and never move it on a Friday without a rollback plan.

Sources: AWS What’s New, “AWS Lambda now supports customer-managed runtimes, giving platform teams centralized control over runtime contents and updates” (generally available November 18, 2026, all commercial Regions, no additional charge); AWS Compute Blog, “Control your AWS Lambda runtimes with customer-managed runtimes” (publisher/consumer model, runtime/version/alias resources, staged rollout, RuntimeInvocations and RuntimeInvocationErrors metrics, cross-account sharing, 7–30-day deletion guardrails, ECR storage pricing); Bref, “AWS Lambda customer-managed runtimes and the Bref v4 roadmap,” Matthieu Napoli, November 20, 2026 (Bref v4 switch from Layers, Ubuntu 26.04, PHP 8.6, 29% cold-start improvement measured 279 ms to 197 ms on identical binaries, v4 planned for end of 2026) — all checked November 29, 2026. Verify current availability and pricing on AWS’s site before building on it; features and prices change.

Leave a Reply

Your email address will not be published. Required fields are marked *