Skip to content

Pod in privilidged mode #137

Description

@mimellin

I'd like to allow my users to work with docker and gpu in pod. The only way to have DinD I know is to start pod as privileged:

apiVersion: v1
kind: Pod
metadata:
  name: mini-pod
spec:
  containers:
  - name: main
    image: ubuntu
    args:
    - sleep infinity
    command:
    - /bin/bash
    - -c
    securityContext:
      privileged: true
    resources:
      limits:
        amd.com/gpu: 1

Usually I'm checking /dev/dri folder to find out what GPU is available in pod, but because of privileged mode I've all 8 gpu visible in this folder.
How can I find out which gpu is reserved for my pod?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions