Enclave boot speed needs to be much faster #216

Open
opened 2026-04-30 20:48:14 +00:00 by ryansquared · 5 comments
ryansquared commented 2026-04-30 20:48:14 +00:00 (Migrated from codeberg.org)

Currently, deploying the Hello World enclave takes nearly a minute to come online. Our timeout is two minutes. If an application has a heavy startup, it will be terminated eagerly. We need to speed up enclave startup time as much as possible. Maybe we do biphasic: wait for Caddy to come up, then wait for attestation endpoint to come up.

Currently, deploying the Hello World enclave takes nearly a minute to come online. Our timeout is two minutes. If an application has a heavy startup, it will be terminated eagerly. We need to speed up enclave startup time as much as possible. Maybe we do biphasic: wait for Caddy to come up, then wait for attestation endpoint to come up.
modalala commented 2026-05-03 10:12:56 +00:00 (Migrated from codeberg.org)

After completing a build, I am getting a timeout.

remote: [x] Preparing deployment...
remote: [x] Provisioning dedicated builder...
remote: [x] Builder ready, downloading source...
remote: [x] Docker image built, building EIF...
remote: [x] Build complete
remote: [x] Uploading and launching...
remote: [x] Waiting for health check...
remote: error: Enclave failed to become healthy: Attestation endpoint did not become healthy within 120 seconds
remote: error: Invalid deployment response

After completing a build, I am getting a timeout. ``` remote: [x] Preparing deployment... remote: [x] Provisioning dedicated builder... remote: [x] Builder ready, downloading source... remote: [x] Docker image built, building EIF... remote: [x] Build complete remote: [x] Uploading and launching... remote: [x] Waiting for health check... remote: error: Enclave failed to become healthy: Attestation endpoint did not become healthy within 120 seconds remote: error: Invalid deployment response ```
anton commented 2026-05-03 19:24:09 +00:00 (Migrated from codeberg.org)

@modalala wrote in https://codeberg.org/caution/platform/issues/216#issuecomment-14220731:

After completing a build, I am getting a timeout.

remote: [x] Preparing deployment...
remote: [x] Provisioning dedicated builder...
remote: [x] Builder ready, downloading source...
remote: [x] Docker image built, building EIF...
remote: [x] Build complete
remote: [x] Uploading and launching...
remote: [x] Waiting for health check...
remote: error: Enclave failed to become healthy: Attestation endpoint did not become healthy within 120 seconds
remote: error: Invalid deployment response

This is likely due to our hard coded timeout limit. What app were you trying to deploy?

https://codeberg.org/caution/platform/issues/135

@ryansquared is currently working on addressing this.

@modalala wrote in https://codeberg.org/caution/platform/issues/216#issuecomment-14220731: > After completing a build, I am getting a timeout. > > ```text > remote: [x] Preparing deployment... > remote: [x] Provisioning dedicated builder... > remote: [x] Builder ready, downloading source... > remote: [x] Docker image built, building EIF... > remote: [x] Build complete > remote: [x] Uploading and launching... > remote: [x] Waiting for health check... > remote: error: Enclave failed to become healthy: Attestation endpoint did not become healthy within 120 seconds > remote: error: Invalid deployment response > ``` This is likely due to our hard coded timeout limit. What app were you trying to deploy? https://codeberg.org/caution/platform/issues/135 @ryansquared is currently working on addressing this.
modalala commented 2026-05-03 23:44:37 +00:00 (Migrated from codeberg.org)

Yes, I think that #135 is probably the correct issue for my comment rather than this one.

I was trying to deploy frost-tools.

Yes, I think that #135 is probably the correct issue for my comment rather than this one. I was trying to deploy `frost-tools`.
ryansquared commented 2026-05-04 18:32:22 +00:00 (Migrated from codeberg.org)

#135 is more about the builder, not the enclave. Builders have a 30 minute timeout, your EIF must be built in 30 minutes (and must send updates every 2 minutes, on my current PR). However, deploying the enclave can take a long time, and we need some way to optimize it.

I think one thing we can do is add a health check path (location TBD) where we just return 200 OK and null response. Then, we can check whether that's up in 120 seconds, and once that timer's reset, we can enter a new check for the enclave attestation.

#135 is more about the _builder_, not the _enclave_. Builders have a 30 minute timeout, your EIF must be _built_ in 30 minutes (and must send updates every 2 minutes, on my current PR). However, deploying the enclave can take a long time, and we need some way to optimize it. I think one thing we can do is add a health check path (location TBD) where we just return 200 OK and null response. Then, we can check whether that's up in 120 seconds, and once that timer's reset, we can enter a new check for the enclave attestation.
anton commented 2026-05-25 03:16:28 +00:00 (Migrated from codeberg.org)
https://codeberg.org/caution/platform/issues/250 < this is the sauce
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
public/platform#216
No description provided.