node-vpn-daemon
TypeScript icon, indicating that this package has built-in type declarations

0.0.17 • Public • Published

node-vpn-daemon

Starts a Openvpn daemon from a node.js program. To be used with the node-vpn-client.

Quick start

npm install node-vpn-daemon
import Daemon from 'node-vpn-daemon'
 
const daemon = new Daemon({
  // params
  // ovpnFiles: Array of strings with the location of the ovpn files (server will be selected randomly from array at every start)
  // host: manager host default 127.0.0.1
  // port: manager port default 1337
  // wait: miliseconds for the program to wait after each command default 5000
})
 
daemon.isRunning().then(isRunning => {
  if (isRunning) {
    daemon.kill()
  } else {
    daemon.start()
  }
})

Readme

Keywords

none

Package Sidebar

Install

npm i node-vpn-daemon

Weekly Downloads

4

Version

0.0.17

License

MIT

Unpacked Size

25.8 kB

Total Files

20

Last publish

Collaborators

  • leoalves001