-
Notifications
You must be signed in to change notification settings - Fork 394
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add containerd-wasm-shims to enable Wasm / WASI workloads #1037
Conversation
Skipping CI for Draft Pull Request. |
1c2b0e7
to
8cee758
Compare
/test pull-azure-sigs |
1 similar comment
/test pull-azure-sigs |
/retest |
/hold |
da3268b
to
d13e0ff
Compare
/test pull-container-image-build |
c072633
to
ff8ed51
Compare
12b6ebb
to
4b78d11
Compare
/test pull-ova-all |
83ed675
to
6216e25
Compare
/hold cancel @jsturtevant I believe this is solid. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/assign @kkeshavamurthy @mboersma
stdout: [ ] | ||
stderr: ["io.containerd.spin.v1: InvalidArgument(\"Shim namespace cannot be empty\")"] | ||
timeout: 0 | ||
grep -E 'io\.containerd\.(slight|spin)\.v1' /etc/containerd/config.toml: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: I think this wouldn't verify both are there are present only one of them (similar to comment above)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are 100% correct. I was having a hard time dealing with .Vars.containerd_wasm_shims_runtime
as it's a comma delimited string ("slight, spin"
). It's much easier to deal with it in Python in Ansible using a string contains.
Do you have a suggestion of how to handle it better in Goss?
@@ -10,6 +10,23 @@ command: | |||
stdout: [] | |||
stderr: [] | |||
timeout: 0 | |||
{{if ne .Vars.containerd_wasm_shims_runtimes ""}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It isn't garmented both runtime would be installed for this check so this could fail if only one is installed. I am not sure this is a big deal at this point for the test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's unfortunate that the containerd wasm shims are packaged together into one release artifact. When you download one, you get both.
I think in the future, I'd like to change the shims to be packaged individually and change the variables / tests in image-builder to allow for individual installation and verification.
I've also opened an issue to add --version
support for the shims. I didn't like the error test. The test does the job of verifying the shim is installed, on the path, and responding in a reasonable way, but I would much rather see something closer to the containerd version verification, so we can ensure we have the specific version installed that we expect.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think in the future, I'd like to change the shims to be packaged individually and change the variables / tests in image-builder to allow for individual installation and verification.
I think it's acceptable to assume both shims for now, and to fix this when their packaging changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/approve
There are a couple of small followup items identified here, but 👍🏻.
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: devigned, mboersma The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What this PR does / why we need it:
This PR adds support for running Wasm workloads using both Fermyon Spin and Deislabs SpiderLightning via Deislabs Containerd Wasm Shims. The same technology is what enables Azure Kubernetes Service to run Wasm / WASI workloads in AKS WASI Node Pools.
Wasm / WASI workloads using a runtime class which informs containerd to delegate the pod workload to the specific shim as described in https://github.com/deislabs/containerd-wasm-shims#using-a-shim-in-kubernetes.
Additional context
This PR stems from this Slack discussion with @elmiko.