Driver Failure: failed to launch command with executor: rpc error: code = Unknown desc = unable to start container process: exec

Hello,
I am getting the above error.
Nomad Version – Nomad v1.8.4
For testing purpose I have set nomad in one of my server’s and using the same server as client.
So in order to start the exec driver I am running the agent as root.
I have tried to enable the exec driver with a non-root user by giving the necessary permissions but it didn’t work out, I have given the nomad binary as well the necessary permissions which are →
cap_sys_ptrace,cap_sys_admin=eip
Yet through non-root user I couldn’t start the exec driver.
If so I have started the exec driver using root the exec driver is getting enabled but I am getting permission denied error’s if i am using the bash shell.
So my suspect is eventhough the agent is running as root, the task’s are being run as different user.
Since the tasks are running as different user, the user which is running is unable to access the bash shell which will be created for every alloc id.
ll
total 0
drwx------ 4 root root 44 Nov 8 03:30 3cdc66a9-43d8-eb78-77ed-ff64cc7a5d80

./nomad alloc fs 3cdc66a9
Mode Size Modified Time Name
drwxrwxrwx 58 B 2024-11-08T03:30:38-05:00 alloc/
drwxrwxrwx 4.0 KiB 2024-11-08T03:30:38-05:00 health-check-task/

./nomad alloc fs 3cdc66a9 health-check-task
Mode Size Modified Time Name
drwxrwxrwx 58 B 2024-11-08T03:30:38-05:00 alloc/
dr-x------ 36 KiB 2024-11-08T03:30:08-05:00 bin/
drwx------ 6 B 2024-11-08T03:30:38-05:00 dev/
drwx------ 8.0 KiB 2024-11-08T03:30:10-05:00 etc/
-rw------- 779 B 2024-11-08T03:30:38-05:00 executor.out
dr-x------ 4.0 KiB 2024-11-08T03:30:10-05:00 lib/
dr-x------ 44 KiB 2024-11-08T03:30:10-05:00 lib64/
drwxrwxrwx 6 B 2024-11-08T03:30:07-05:00 local/
drwxrwxrwx 60 B 2024-11-08T03:30:07-05:00 private/
drwx------ 6 B 2024-11-08T03:30:38-05:00 proc/
dr-x------ 16 KiB 2024-11-08T03:30:08-05:00 sbin/
drwxrwxrwx 60 B 2024-11-08T03:30:07-05:00 secrets/
drwx------ 6 B 2024-11-08T03:30:38-05:00 sys/
dtrwxrwxrwx 6 B 2024-11-08T03:30:07-05:00 tmp/
drwx------ 158 B 2024-11-08T03:30:10-05:00 usr/

So how can we dynamically give execute access for all user’s for the directories being created under chroot isolation?