G
G
gadzhi152018-07-23 22:16:55
Python
gadzhi15, 2018-07-23 22:16:55

VPN connection in Python. How best to implement?

There are Python scripts (for each client) that are run by cron. The script connects to remote servers. One of the clients does not provide a direct connection to the server, but offers to implement a vpn connection to the server?
Is it possible to implement this vpn connection using Python only for one copy of the script? And if possible, how to implement it? Or does the VPN client need to be implemented using OS tools? But then other copies of the script won't work for me.
OS: Ubuntu Server

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Doc44, 2018-07-23
@gadzhi15

The VPN connection is established by means external to your program . The maximum that you need to do from your program is to call the VPN connection utility and, upon completion, disconnect through the same utility.
After that, the remote server becomes available, for example, at the address 10.10.0.5, at which it was not available before the connection was established.
After that, you access this very 10.10.0.5 from this instance of your program.
In other copies - you turn to other servers, to other addresses.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question