V
V
Vasily Ivanov2021-04-09 17:53:39
linux
Vasily Ivanov, 2021-04-09 17:53:39

How to use subprocess without sudo?

I have a fiddle which executes the following command

openvpn_process = subprocess.Popen(['sudo', 'openvpn', '--config', 'tmp/tmp67fv65'])


How can I run this same command without sudo?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
H
hto_on, 2021-04-09
@hto_on

add openvpn command to sudoers file
user ALL=(ALL) NOPASSWD:/usr/sbin/openvpn

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question