How to run write a bash script to do a task after an
openvpn connection as
#!/bin/bash openvpn --config file.ovpn (step 1) RUN THE TASK AFTER THE CONNECTION (step 2) THEN DISCONNECT FROM THE OPENVPN (step 3)
My problem is how to move from the step 1 to step 2. I tried
daemon options in
openvpn to trigger step 2 in background, but in this case, we do not know when step 2 is finished to trigger step 3.
The problem is how to use
openvpn as a regular command in a
bash script to go to the next line when the connection is established.