Accessing /dev/fuse from a workspace

You must have access to /dev/fuse to use fuse-overlayfs. This section describes how to make /dev/fuse accessible to workspace containers.

  • For OpenShift versions older than 4.15, the administrator has enabled access to /dev/fuse by following Configuring fuse-overlayfs.

  • Determine a workspace to use fuse-overlayfs with.

  1. Use the pod-overrides attribute to add the required annotations defined in Configuring fuse-overlayfs to the workspace. The pod-overrides attribute allows merging certain fields in the workspace pod’s spec.

    For OpenShift versions older than 4.15:

    $ kubectl patch devworkspace <DevWorkspace_name> \
      --patch '{"spec":{"template":{"attributes":{"pod-overrides":{"metadata":{"annotations":{"io.kubernetes.cri-o.Devices":"/dev/fuse","io.openshift.podman-fuse":""}}}}}}}' \

    For OpenShift version 4.15 and later:

    $ kubectl patch devworkspace <DevWorkspace_name> \
      --patch '{"spec":{"template":{"attributes":{"pod-overrides":{"metadata":{"annotations":{"io.kubernetes.cri-o.Devices":"/dev/fuse"}}}}}}}' \
Verification steps
  1. Start the workspace and verify that /dev/fuse is available in the workspace container.

    $ stat /dev/fuse

After completing this procedure, follow the steps in Enabling fuse-overlayfs with a Configmap to use fuse-overlayfs for Podman.