Skip to content

Release does not deploy the operated Lambdas: detect which components a release changed, and auto-deploy code-only changes #1444

Closed

Description

@scttfrdmn

Problem

A spawn release does not deploy the spore.host-operated Lambdas. Each one is redeployed only when someone runs its script or sam deploy. #654 and #768 made the resulting skew visible: every deploy path stamps spawn:version. Nothing closes the skew.

Evidence from v0.151.0 (record on #1440):

Proposal (two parts, separable)

  1. Detect (cheap, no new credentials). Add a release-time job that lists, per operated component, whether its compiled inputs changed since the deployed tag. It would use go list -deps over each Lambda package, plus the role, template and mapping scripts. It posts the list on the release PR as a deploy checklist.

    • Optionally, a scheduled check that reads each function's spawn:version and files or updates an issue when one lags the latest release, or lags a changed input.
  2. Deploy (needs an owner decision). After the release job is green, deploy code-only changes automatically: update-function-code / SAM with an unchanged parameter set except Version. Verify them the same way they are verified by hand now:

    • CodeSha256 equals the built zip;
    • zero config drift against a pre-deploy snapshot;
    • the change set contains only Code/Tags.

    Anything touching IAM (role scripts, inline policies), event-source mappings or stack parameters other than Version stays a manual step, flagged by part 1. Those are the changes that have broken production before (2026-10-04, Every spawn launch fails on v0.129.0/v0.130.0: spored role policy rejected (MalformedPolicyDocument) #1069).

Decision needed

Part 2 means giving GitHub Actions write access to production Lambdas in 966362334030 through an OIDC role, scoped to lambda:UpdateFunctionCode/TagResource on the named functions plus the SAM stack. That is a security-posture call for the owner. Part 1 can ship without it.

Activity

  1. added this to the v0.152.0 milestone on Oct 30, 2026
  2. added
    enhancement
    on Oct 30, 2026
  3. scttfrdmn commented on Oct 30, 2026

    @scttfrdmn
    ContributorAuthor

    Owner approved the plan (2026-10-30). The plan, with one correction:

    1. This issue is now detection only (part 1): a release-time job computes which operated components a release changed and posts a deploy checklist on the release PR. Details are in the agent brief below.

    2. Part 2 (approval-gated deploy of code-only changes) moved to Approval-gated CI deploy of code-only Lambda changes after a release (OIDC role, production environment) #1445.

    3. Dropped: "orchestrators should boot the CLI's spored". I had proposed this on the premise that orchestrator lag leaves sweep and pipeline members on the previous spored. The code says otherwise:

      • Detached sweeps: members boot the user data and tags the CLI rendered (withMemberBootstrap, lambda/sweep-orchestrator/legacy.go:79), so spored already follows the launching CLI. The Lambda's own Version is used only for legacy param sets from older CLIs.
      • Pipelines: stage instances pin spored to the orchestrator's release on purpose (lambda/pipeline-orchestrator/main.go:1200, Pin spored to the launching CLI's version (install from spawn/versions/<ver>/), not the unversioned latest #1412). The stage runner is spored run-pipeline-stage, so the orchestrator and spored are one contract. Pinning to the CLI would break that.

      So orchestrator lag affects the orchestrator's own logic and its spawn:version stamp, not the spored on members. The issue body's line saying otherwise is wrong.

  4. scttfrdmn commented on Oct 30, 2026

    @scttfrdmn
    ContributorAuthor

    Shipped in #1446 (merged as b3b8736). The deploy checklist (make deploy-checklist) runs in the release workflow and posts on the release PR. Its first live run is at v0.152.0. Part 2 is #1445.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions