feat(key-provider): single-container image with systemd lifecycle#623
Open
feat(key-provider): single-container image with systemd lifecycle#623
Conversation
…agement Consolidate aesmd and gramine-sealing-key-provider into a single container to eliminate cross-container startup ordering issues that caused cascading failures after power outage reboots. Move config to /etc so it no longer depends on external disk mounts.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
dstack-key-provider.service) usingdocker run --rminstead of docker-composesgx_default_qcnl.confto/etc/dstack-key-provider/, removing dependency on external disk mount (/opt/dstack)ghcr.io/dstack-tee/dstack/gramine-sealing-key-providerBackground
After power outage reboots, docker daemon starts before
/opt/dstack(external disk) is mounted. The old docker-compose deployment bind-mounted config from that disk, causing aesmd to fail (exit 127), which cascaded to key-provider failure, which took down VMM.Changes
key-provider-build/Dockerfilekey-provider-build/entrypoint.shexecs gramine-sgx for proper signal handlingkey-provider-build/dstack-key-provider.serviceRestart=on-failure, referencesghcr.ioimage.github/workflows/key-provider-release.ymlkey-provider-v*tagsDeployment
Release
git tag key-provider-v0.1.0 git push origin key-provider-v0.1.0 # GitHub Actions builds and pushes to ghcr.io automaticallyTest plan
docker build -t test-key-provider key-provider-build/systemctl status dstack-key-providershows active