nvEncOpenEncodeSessionEx return 2 in docker

I tried run Video_Codec_SDK_10.0.26 Samples AppEncGL in docker.I get error 2 when call m_nvenc.nvEncOpenEncodeSessionEx.I do not understand why.
nvidia-smi info :
Thu Nov 28 10:06:29 2024
±----------------------------------------------------------------------------------------+
| NVIDIA-SMI 555.58 Driver Version: 555.58 CUDA Version: 12.5 |
|-----------------------------------------±-----------------------±---------------------+
| GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+========================+======================|
| 0 NVIDIA GeForce RTX 2060 Off | 00000000:01:00.0 On | N/A |
| 27% 33C P0 34W / 190W | 280MiB / 6144MiB | 0% Default |
| | | N/A |
±----------------------------------------±-----------------------±---------------------+

±----------------------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=========================================================================================|
±----------------------------------------------------------------------------------------+
commond RUN the container :
docker run -d --restart=on-failure
–cap-add=SYS_PTRACE
–gpus all
-e USER=pxy
-e PASSWORD=123456
-e GID=1001
-e UID=1001
–shm-size=1024m
-p 10022:22
-p 14000:4000
-p 10002:10002
-p 10011:10011
-it
–privileged
-e NVIDIA_VISIBLE_DEVICES=all
-e NVIDIA_DRIVER_CAPABILITIES=all
gezp/ubuntu-desktop:22.04-cu12.2.2
Please help me for this issue.Thank you.