Skip to content
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

engine: instructions on using alternative container runtimes #17517

Merged
merged 1 commit into from
Jun 26, 2023

Conversation

dvdksn
Copy link
Contributor

@dvdksn dvdksn commented Jun 9, 2023

Signed-off-by: David Karlsson 35727626+dvdksn@users.noreply.github.com

Proposed changes

This PR adds information about how to use alternative container runtimes with Docker Engine.

It includes both the legacy runtime configuration, and the new shimv2 option.

Related issues (optional)

Closes #17247

@netlify
Copy link

netlify bot commented Jun 9, 2023

Deploy Preview for docsdocker ready!

Name Link
🔨 Latest commit 15303cf
🔍 Latest deploy log https://app.netlify.com/sites/docsdocker/deploys/648b26e3ec119e0008976ec0
😎 Deploy Preview https://deploy-preview-17517--docsdocker.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@dvdksn dvdksn force-pushed the engine/alternative-runtimes branch 2 times, most recently from 72c50f8 to af937c4 Compare June 9, 2023 12:24
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
@dvdksn
Copy link
Contributor Author

dvdksn commented Jun 9, 2023

/cc @utam0k

Copy link

@jprendes jprendes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@dvdksn dvdksn force-pushed the engine/alternative-runtimes branch 2 times, most recently from c489d76 to 5457f59 Compare June 9, 2023 15:26
Copy link
Contributor

@corhere corhere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there going to be a separate PR to update the engine reference docs?

engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved

### Use containerd shims

Docker Engine supports the use of containerd runtime shims.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, use of containerd runtime shims is mandatory. It's just that a few alternative runtimes support (or require) runC's containerd shim when used with containerd. Docker transparently handles this as an implementation detail when using a runtime registered with a path instead of a runtimeType. I don't think this necessarily needs to be fully explained in the user-facing documentation, though.

engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
$ docker run --runtime io.containerd.kata.v2 hello-world
```

#### Configure shims
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When runtimeType is io.containerd.runc.v1 or io.containerd.runc.v2, these are the available options. Though most users of the runC shim would be best served by letting the daemon configure the runC shim options automatically by configuring a runtime using "path" instead of "runtimeType" so it's probably better not to mention it here, and only document those options in reference documentation for advanced users, or not document it at all.

engine/alternative-runtimes.md Outdated Show resolved Hide resolved

Examples of alternative container runtimes that you can use include:

- [youki](https://github.com/containers/youki){: target="blank" rel="noopener"}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might also be worth mentioning crun since it's production-quality, unlike youki

@utam0k
Copy link

utam0k commented Jun 10, 2023

/cc @utam0k

I am very happy to have youki mentioned here. We are vendor-neutral. That's why it's hard for us to appeal. We are very happy to have this opportunity.

@dvdksn dvdksn force-pushed the engine/alternative-runtimes branch 10 times, most recently from cce4a96 to e8f4090 Compare June 12, 2023 21:07
@dvdksn
Copy link
Contributor Author

dvdksn commented Jun 12, 2023

I've just pushed some changes to the dockerd reference page: docker/cli#4344

I've moved some bits from this PR there, as not to duplicate information. These changes deemphasize the legacy path config.

@dvdksn dvdksn force-pushed the engine/alternative-runtimes branch 2 times, most recently from 334ea5c to 73820ba Compare June 13, 2023 03:40
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
@dvdksn dvdksn force-pushed the engine/alternative-runtimes branch 4 times, most recently from c8eb6f6 to 135fc2d Compare June 14, 2023 12:56
@dvdksn
Copy link
Contributor Author

dvdksn commented Jun 14, 2023

Copy link
Contributor

@corhere corhere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@dvdksn dvdksn requested a review from a team June 15, 2023 07:54
aevesdocker
aevesdocker previously approved these changes Jun 15, 2023
Copy link
Contributor

@aevesdocker aevesdocker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two non-blocking pedantic comments from me

engine/alternative-runtimes.md Show resolved Hide resolved
engine/alternative-runtimes.md Outdated Show resolved Hide resolved
Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
Copy link
Contributor

@aevesdocker aevesdocker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@dvdksn dvdksn added the status/do-not-merge Pull requests that are awaiting some event or decision before they can be merged. label Jun 15, 2023
@dvdksn
Copy link
Contributor Author

dvdksn commented Jun 15, 2023

holding the merge until cli reference has been merged and backported.

@dvdksn dvdksn merged commit 9c71f46 into docker:main Jun 26, 2023
8 of 9 checks passed
@dvdksn dvdksn deleted the engine/alternative-runtimes branch June 26, 2023 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/do-not-merge Pull requests that are awaiting some event or decision before they can be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for alternative shimv2 runtimes needs documentation
5 participants