Run nested containers in workspaces
Run nested containers in OpenShift Dev Spaces workspaces using tools like Podman. This feature uses Linux kernel user namespaces for isolation, so that users can build and run container images within their workspaces.
Before you begin
- You have an active
ocsession with administrative permissions to the OpenShift cluster. See This page is not included, but the link has been rewritten to point to the nearest parent document.Getting started with the CLI. - You have an instance of OpenShift Dev Spaces running in OpenShift.
About this task
Important:
Previously created workspaces cannot be started after enabling this feature. Users must create new workspaces.
Important:
- This feature is available on OpenShift 4.20 and later versions.
Procedure
Configure the
CheCluster custom resource to enable container run capabilities:
oc patch checluster/devspaces -n openshift-devspaces \
--type='merge' -p \
'{"spec":{"devEnvironments":{"disableContainerRunCapabilities":false}}}'Results
- Create a new workspace and verify that Podman is available:
podman run --rm hello-world