mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-25 02:26:12 +02:00
merge: include verified Daytona lock handoff
Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
commit
b681d736be
3 files changed
+26
-2
No files matched your search
@@ -432,6 +432,7 @@ jobs:
|
||||
IMAGE_TAG: ghcr.io/paperclipai/paperclip-daytona-runner:e2e-content-${{ needs.catalog.outputs.daytona_image_content_id }}
|
||||
IMAGE_CACHE: ghcr.io/paperclipai/paperclip-daytona-runner:e2e-buildcache-amd64
|
||||
TARGET_SHA: ${{ needs.authorize.outputs.target_sha }}
|
||||
TARGET_LOCK_SHA256: ${{ needs.target_lock.outputs.lock_sha256 }}
|
||||
TARGET_REF: ${{ needs.authorize.outputs.target_ref }}
|
||||
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
|
||||
run: |
|
||||
@@ -445,6 +446,7 @@ jobs:
|
||||
exit 0
|
||||
fi
|
||||
[[ "$IMAGE_CONTENT_ID" =~ ^[0-9a-f]{64}$ ]]
|
||||
[[ "$TARGET_LOCK_SHA256" =~ ^[0-9a-f]{64}$ ]]
|
||||
identity="^https://github.com/${GITHUB_REPOSITORY}/.github/workflows/runner-full-stack-e2e.yml@"
|
||||
if docker buildx imagetools inspect "$IMAGE_TAG" >/dev/null 2>&1; then
|
||||
digest="$(docker buildx imagetools inspect "$IMAGE_TAG" --format '{{json .Manifest.Digest}}' | tr -d '"')"
|
||||
@@ -464,6 +466,7 @@ jobs:
|
||||
--platform linux/amd64 \
|
||||
--build-arg "PAPERCLIP_RUNNER_CONTENT_ID=${IMAGE_CONTENT_ID}" \
|
||||
--build-arg "PAPERCLIP_RUNNER_SOURCE_REVISION=${TARGET_SHA}" \
|
||||
--build-arg "PAPERCLIP_RUNNER_LOCK_SHA256=${TARGET_LOCK_SHA256}" \
|
||||
--file docker/daytona-runner/Dockerfile \
|
||||
--tag "$IMAGE_TAG" \
|
||||
"${cache_args[@]}" \
|
||||
|
||||
@@ -101,6 +101,11 @@ bot. The trusted workflow supplies this resolved lockfile as an immutable artifa
|
||||
The complete resolved lockfile must match `PAPERCLIP_RUNNER_LOCK_SHA256` before
|
||||
package installation or lifecycle execution. Review and refresh that digest
|
||||
with source dependency changes; registry-time resolution drift fails closed.
|
||||
The Product E2E workflow resolves one lockfile before the image build. It
|
||||
verifies the downloaded artifact, then passes that artifact's SHA-256 as the
|
||||
`PAPERCLIP_RUNNER_LOCK_SHA256` build argument. The Dockerfile checks the resolved
|
||||
lock against this value before installation. The fixed Dockerfile default is
|
||||
for standalone builds; it must not replace a campaign's verified lock digest.
|
||||
Refresh exact runtime versions and qualification digests together; never download
|
||||
dependencies when a task starts. Grok's additive native ACP profile keeps its
|
||||
qualified 1.0.13 executable at a verified package path. It does not replace the
|
||||
|
||||
@@ -42,6 +42,8 @@ describe("runner E2E Daytona image contract", () => {
|
||||
),
|
||||
]);
|
||||
const normalizedDockerfile = dockerfile.replace(/\\\r?\n\s*/g, " ");
|
||||
const daytonaImageJob = workflow.match(/^ daytona_image:\n[\s\S]*?(?=^ \w+:)/m)?.[0];
|
||||
expect(daytonaImageJob).toBeDefined();
|
||||
expect(dockerfile).toContain("--bin paperclip-runnerd");
|
||||
expect(dockerfile).toContain("build-provider-pack.mjs /provider-pack");
|
||||
expect(normalizedDockerfile).not.toContain(
|
||||
@@ -106,6 +108,22 @@ describe("runner E2E Daytona image contract", () => {
|
||||
expect(workflow).toContain(
|
||||
'--build-arg "PAPERCLIP_RUNNER_CONTENT_ID=${IMAGE_CONTENT_ID}"',
|
||||
);
|
||||
expect(daytonaImageJob).toContain(
|
||||
"TARGET_LOCK_SHA256: ${{ needs.target_lock.outputs.lock_sha256 }}",
|
||||
);
|
||||
expect(daytonaImageJob).toContain(
|
||||
'[[ "$TARGET_LOCK_SHA256" =~ ^[0-9a-f]{64}$ ]]',
|
||||
);
|
||||
expect(daytonaImageJob).toContain(
|
||||
'--build-arg "PAPERCLIP_RUNNER_LOCK_SHA256=${TARGET_LOCK_SHA256}"',
|
||||
);
|
||||
expect(
|
||||
daytonaImageJob!.indexOf('[[ "$TARGET_LOCK_SHA256" =~ ^[0-9a-f]{64}$ ]]'),
|
||||
).toBeLessThan(
|
||||
daytonaImageJob!.indexOf(
|
||||
'--build-arg "PAPERCLIP_RUNNER_LOCK_SHA256=${TARGET_LOCK_SHA256}"',
|
||||
),
|
||||
);
|
||||
expect(workflow).toContain(
|
||||
"IMAGE_CACHE: ghcr.io/paperclipai/paperclip-daytona-runner:e2e-buildcache-amd64",
|
||||
);
|
||||
@@ -124,8 +142,6 @@ describe("runner E2E Daytona image contract", () => {
|
||||
expect(workflow).toContain(`docker buildx imagetools inspect "$immutable"`);
|
||||
expect(workflow).toContain(`--format '{{json .Image}}'`);
|
||||
expect(workflow).not.toContain(`docker --config "$anonymous_config" pull`);
|
||||
const daytonaImageJob = workflow.match(/^ daytona_image:\n[\s\S]*?(?=^ \w+:)/m)?.[0];
|
||||
expect(daytonaImageJob).toBeDefined();
|
||||
// Remote Daytona manifests must use registry inspection. Local oracle
|
||||
// images in the test job can still use the Docker daemon.
|
||||
expect(daytonaImageJob).not.toContain("docker image inspect");
|
||||
|
||||
Reference in new issue
Block a user