Add env DISPLAY and x11 mount volume

NOOB question , I have a docker that used x11 . The docker run incorporates the env and mount volume.
–env=“DISPLAY” -v /tmp/.X11-unix:/tmp/.X11-unix:rw
However when I move it to a pod i have errors
Could not connect to display
Could not connect to any X display.
command terminated with exit code 1
Is there any way I can add the above docker run args in a yaml or Kubectl set env ?

Only if your kubernetes nodes are running X, which seems unlikely.

Hi, is there a way to install Xorg on kubernetes nodes, so x11 socket can be mounted on a container? Thanks